Comments (14)
@herkulano You can meanwhile use @jas99/graphql-resolver-codegen
from graphqlgen.
@zachariahtimothy Lol yes was on windows, and line ending must be related to that. FYI linux/mac user most of time. I have heard they are finally gonna move to /r, good for them; but windows still big blob of useless code 😆.
Anyways without any changes all code compiled for me, maybe that's also OS sensitive.
I would personally recommend @divyenduz to use parcel with parcel-plugin-typescript. It will bundle into single file even commonjs.
In case you are interested, here's example for opensource project I have been working on; and is using parcel for bundling typescript
https://github.com/singh/singh/blob/master/package.json
Thx
from graphqlgen.
@divyenduz #49 solves the issue
from graphqlgen.
Can you share a small reproduction example?
from graphqlgen.
You can use this example https://github.com/prisma/prisma-examples/tree/master/typescript-graphql, bump graphql-resolver-codegen
version to 0.2.3
and run yarn generate-resolvers
.
from graphqlgen.
@marktani I can confirm the issue
from graphqlgen.
I am also experiencing the same issue. @Jas99 When I try yours I get env: node\r: No such file or directory
. Tried to find your fork to comment but was unsuccessful.
from graphqlgen.
I published my version to npm as @zachariahtimothy/graphql-resolver-codegen for testing purposes and it works. Fixed and created a pull request. #49
from graphqlgen.
@zachariahtimothy Awesome mustache!! 🥇
Its weird cause it worked for me and seems like might also worked for @herkulano .
Quick look at ur pr #49 ; your include seems redundant, though need to double chk.
from graphqlgen.
Haha @Jas99 thanks so much! I cannot say my PR was the perfect solution, but when I added the glob include it immediately compiled all code. Noticed in node_modules dist code that they really were missing.
As to your fork, I am unsure why I received that. I tried a few ways to execute the binary and nothing worked. For a minute I thought maybe node got blown away. Maybe it is just a line ending issue or something? Are you on Windows by chance?
from graphqlgen.
This is related to recent changes to have TS declaration included --declaration
, some export are missing so compilation can't work, these export should be added before a new release can be published by @divyenduz .
from graphqlgen.
@zachariahtimothy your patch works fine 👍
from graphqlgen.
@brikou, @Jas99 : Can either of you raise a PR if possible with the suggested changes, would love to merge that :)
from graphqlgen.
Thanks! merged and released via 0.2.4@beta
. Thanks to everyone involved 🎉 🙏
from graphqlgen.
Related Issues (20)
- Generated resolver types have typo "resolver" instead of "resolve" HOT 3
- Missing custom types properties in suggested model types. HOT 7
- graphqlgen gives `UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'map' of undefined` HOT 10
- graphqlgen + Nexus? HOT 1
- check args of query at port 4000 is no I expect. HOT 3
- Cannot find module ts-node HOT 4
- Incorrect type for arrays of arrays resolver HOT 2
- Make IResolvers compatible with IResolversParameter from graphql-tools
- graphqlgen-json-schema schema.json missing properties HOT 1
- Add ability to disable generation of DelegatedParentResolver types HOT 1
- Does not work with the typescript-advanced example project
- Does not generate resolvers for relation fields
- The resolvers generates incorrect return values for array of string or null
- Duplicate IResolvers definitions breaks build HOT 11
- Missing Query_ prefix in graphqlgen.js input type for Query causing Flow error
- Allow using `import` in model files
- Vulnerability in js-yaml dependency HOT 3
- Subscription types are incorrect
- Apollo Federation support HOT 4
- Add the ability to abort request if it is in progress
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from graphqlgen.