du5rte / graphql-mongodb-projection Goto Github PK
View Code? Open in Web Editor NEWGraphQL mongoDB projections generator
License: MIT License
GraphQL mongoDB projections generator
License: MIT License
In some cases I get an error when generating a projection.
An example of failing info is available here: http://pastebin.com/1U1sMzvd
Here is the interesting part of the stack trace:
TypeError: Cannot read property 'selections' of null
at infoToProjection (...graphql-mongodb-projection/dist/index.js:13:30)
at context.selectionSet.selections.reduce (/...graphql-mongodb-projection/dist/index.js:18:43)
at Array.reduce (native)
at infoToProjection (...s/graphql-mongodb-projection/dist/index.js:13:42)
thanks for your great lib, but recently, the field fieldASTs
is renamed to fieldNodes
in graphql-js v0.8.0
could you please adapt this change ?
Is there an alternative for sql databases?
Since d855eea I am getting the following error on a fresh install.
module.js:540
throw err;
^
Error: Cannot find module 'babel-runtime/core-js/object/entries'
at Function.Module._resolveFilename (module.js:538:15)
at Function.Module._load (module.js:468:25)
at Module.require (module.js:587:17)
at require (internal/module.js:11:18)
at Object.<anonymous> (/Users/albert/Projects/pledgeit-services/users/node_modules/graphql-mongodb-projection/lib/index.js:7:16)
at Module._compile (module.js:643:30)
at Module._compile (/Users/albert/Projects/pledgeit-services/users/node_modules/pirates/lib/index.js:91:24)
at Module._extensions..js (module.js:654:10)
at Object.newLoader [as .js] (/Users/albert/Projects/pledgeit-services/users/node_modules/pirates/lib/index.js:96:7)
at Module.load (module.js:556:32)
at tryModuleLoad (module.js:499:12)
at Function.Module._load (module.js:491:3)
at Module.require (module.js:587:17)
at require (internal/module.js:11:18)
at Object.<anonymous> (/Users/albert/Projects/pledgeit-services/users/lib/graphql/userResolvers.js:1:1)
at Module._compile (module.js:643:30)
at Module._compile (/Users/albert/Projects/pledgeit-services/users/node_modules/pirates/lib/index.js:91:24)
at Module._extensions..js (module.js:654:10)
at Object.newLoader [as .js] (/Users/albert/Projects/pledgeit-services/users/node_modules/pirates/lib/index.js:96:7)
at Module.load (module.js:556:32)
at tryModuleLoad (module.js:499:12)
at Function.Module._load (module.js:491:3)
Adding babel-runtime
to the packages seems to fix this.
This package supports nested fields like { 'profile.name': true }
?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.