Closed pcvvelzen closed 4 years ago
Did you try export NODE_PATH=./node_modules
?
https://github.com/hirochachacha/graphql-auto-transformer#4-export-node_path
let me know if the issue persists
I did have to run npm i -g graphql-auto-transformer
in the build step to get it working.
I did have to run
npm i -g graphql-auto-transformer
in the build step to get it working.
How do you add this to build step?
After following the installation instructions (step1) with npm install and (step 2) adding graphql-auto-transformer to the
transform.conf.json
file of my Amplify API:When attempting to use @auto directive in my model
I get the following error
When removing the @auto directory from my schema and running
amplify push -y
I get the error thatgraphql-auto-transformer
module could not be found, while the module is present in.\node_modules\graphql-auto-transformer
(after being installed through npm as mentioned in thereadme.MD
).This was only resolved through installing the package globally:
npm install graphql-auto-transformer -g
.Note: I am not certain as if this issue is related to this package, or to the Amplify CLI perhaps containing a bug in combination with Windows, with finding the correct relative path to
./node_nodules/graphql-auto-transformer