Missing dependencies on NextJS build
koenpunt opened this issue · 0 comments
koenpunt commented
My build fails with the following output;
info - Creating an optimized production build
Failed to compile.
./node_modules/apollo-link-sentry/lib/SentryLink.js:6:0
Module not found: Can't resolve '@sentry/types'
Import trace for requested module:
./node_modules/apollo-link-sentry/lib/index.js
./src/utils/client.ts
./src/utils/useApollo.ts
./src/pages/_app.tsx
https://nextjs.org/docs/messages/module-not-found
./node_modules/apollo-link-sentry/lib/sentry.js:4:0
Module not found: Can't resolve '@sentry/minimal'
Import trace for requested module:
./node_modules/apollo-link-sentry/lib/SentryLink.js
./node_modules/apollo-link-sentry/lib/index.js
./src/utils/client.ts
./src/utils/useApollo.ts
./src/pages/_app.tsx
https://nextjs.org/docs/messages/module-not-found
I see that @sentry/types
and @sentry/minimal
are as dev dependencies in the package.json
, but apparently are also required in production? Or maybe the dependencies of @sentry/browser
have changed, and having that as a peer dependency is no longer enough?