Node_modules dependencies


I’m using serverless framework for the first time;
I have a nice bootstrap function using graphql but on deploy some packages are missing [ like graphql or graphql-yoga for example ]

There are all on dependencies and not dev and I’m a little confuse about that :frowning:
I’m using serverless-webpack with the custom configuration but I have an error: Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema.

“dependencies”: {
“graphql”: “^0.13.2”,
“graphql-config”: “^2.0.1”,
“graphql-import”: “^0.6.0”,
“graphql-playground-middleware-lambda”: “^1.7.1”,
“graphql-tag”: “^2.9.2”,
“graphql-tools”: “^3.0.4”,
“graphql-yoga”: “^1.14.10”,
“prisma-binding”: “^2.1.0”

“errorMessage”: “Cannot find module ‘prisma-binding’”,
“errorType”: “Error”,
“stackTrace”: [


Thank youuu :slight_smile:

By default webpack will use tree shaking to remove dead code. Unfortunately it can get this wrong sometimes. I’ve had success using the webpack-node-externals plugin to make sure it packages all of your dependencies externally.

Thanks for the reply, actually I removed and re-create my app and all package are loaded… weird but it works now

1 Like