UNPKG

@userlab/dx

Version:

Build efficient GraphQL backend

24 lines (23 loc) 720 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getService = void 0; var graphql_1 = require("graphql"); var joinMonsterResolve_1 = require("./joinMonsterResolve"); var getService = function (objectType) { return { type: objectType, args: { id: { type: new graphql_1.GraphQLNonNull(graphql_1.GraphQLID) }, }, extensions: { joinMonster: { where: function (table, _a) { var id = _a.id; return table + ".id = '" + id + "'"; }, }, }, resolve: joinMonsterResolve_1.joinMonsterResolve, }; }; exports.getService = getService;