Skip to content

graphql-tools don't compile with typescript #752

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
fosk06 opened this issue Apr 25, 2018 · 2 comments
Closed

graphql-tools don't compile with typescript #752

fosk06 opened this issue Apr 25, 2018 · 2 comments

Comments

@fosk06
Copy link

fosk06 commented Apr 25, 2018

I c'ant compile a very basic file with graphql tools.
The files are in the zip folder.
The error i have when i try "tsc" command :

node_modules/@types/graphql/execution/execute.d.ts(1,44): error TS2307: Cannot find module '../error'. node_modules/@types/graphql/index.d.ts(150,8): error TS2307: Cannot find module './type'. node_modules/@types/graphql/index.d.ts(234,8): error TS2307: Cannot find module './language'. node_modules/@types/graphql/index.d.ts(245,8): error TS2307: Cannot find module './execution'. node_modules/@types/graphql/index.d.ts(247,52): error TS2307: Cannot find module './subscription'. node_modules/@types/graphql/index.d.ts(282,8): error TS2307: Cannot find module './validation'. node_modules/@types/graphql/index.d.ts(285,78): error TS2307: Cannot find module './error'. node_modules/@types/graphql/index.d.ts(380,8): error TS2307: Cannot find module './utilities'. node_modules/@types/graphql/language/lexer.d.ts(3,29): error TS2307: Cannot find module '../error'. src/index.ts(2,38): error TS2307: Cannot find module 'graphql-tools'.

example.zip

@alherd-by
Copy link

alherd-by commented Jun 26, 2018

@fosk06
Try to change
{ enforce: "pre", test: /.js$/, loader: "source-map-loader" }
to
{ enforce: "pre", test: /.js$/, loader: "source-map-loader", exclude: [/node_modules/] }
I had same problem

@stubailo
Copy link
Contributor

Marking this as part of #704 - going to close this and let's discuss typescript improvements there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants