Edit: The problem seems to be with next-optimized-images so I will try to delete this
[X] I HAVE READ THE FAQ AND MY PROBLEM WAS NOT DESCRIBED THERE
[] I WILL GIVE 10$ TO CHARITY IF MY SOLUTION WAS ACTUALLY IN THE README/FAQ
Are you trying to transpile a local package or an npm package?
Local
Describe the bug
I can only build my project like this:
module.exports = withTM(withPlugins(...
When I try the documented way, I get this error:
extension:build: TypeError: parsedPhaseConfig.substr is not a function
extension:build: at isInCurrentPhase (/Users/oskar/code/monorepo/node_modules/.pnpm/next-compose-plugins@2.2.1/node_modules/next-compose-plugins/lib/phases.js:23:25)
extension:build: at /Users/oskar/code/monorepo/node_modules/.pnpm/next-compose-plugins@2.2.1/node_modules/next-compose-plugins/lib/compose.js:85:41
extension:build: at Array.forEach (<anonymous>)
extension:build: at composePlugins (/Users/oskar/code/monorepo/node_modules/.pnpm/next-compose-plugins@2.2.1/node_modules/next-compose-plugins/lib/compose.js:77:11)
extension:build: at /Users/oskar/code/monorepo/node_modules/.pnpm/next-compose-plugins@2.2.1/node_modules/next-compose-plugins/lib/index.js:22:38
extension:build: at Object.normalizeConfig (/Users/oskar/code/monorepo/node_modules/.pnpm/next@12.0.3_8d19e71f537159d0e4cfe785a045975c/node_modules/next/dist/server/config-shared.js:109:18)
extension:build: at Object.loadConfig [as default] (/Users/oskar/code/monorepo/node_modules/.pnpm/next@12.0.3_8d19e71f537159d0e4cfe785a045975c/node_modules/next/dist/server/config.js:404:47)
extension:build: at async Span.traceAsyncFn (/Users/oskar/code/monorepo/node_modules/.pnpm/next@12.0.3_8d19e71f537159d0e4cfe785a045975c/node_modules/next/dist/trace/trace.js:74:20)
extension:build: at async /Users/oskar/code/monorepo/node_modules/.pnpm/next@12.0.3_8d19e71f537159d0e4cfe785a045975c/node_modules/next/dist/build/index.js:87:24
extension:build: at async Span.traceAsyncFn (/Users/oskar/code/monorepo/node_modules/.pnpm/next@12.0.3_8d19e71f537159d0e4cfe785a045975c/node_modules/next/dist/trace/trace.js:74:20)
webapp:build: info - Checking validity of types...
extension:build: ELIFECYCLE Command failed with exit code 1.
extension:build: Error: command finished with error: exit status 1
To Reproduce
Steps to reproduce the behavior (a reproduction is even better):
Expected behavior
A clear and concise description of what you expected to happen.
Setup
Next.js version: 12.0.7
next-transpile-modules version: 9.0.0
Node.js version: v17.1.0
npm/yarn version: PNPM 6.24.4
Operating System: MacOS Big Sur 11.5.2
Webpack: 4
Additional context
Add any other context about the problem here.
Edit: The problem seems to be with
next-optimized-images
so I will try to delete thisAre you trying to transpile a local package or an npm package? Local
Describe the bug
I can only build my project like this:
module.exports = withTM(withPlugins(...
When I try the documented way, I get this error:
To Reproduce Steps to reproduce the behavior (a reproduction is even better):
Expected behavior A clear and concise description of what you expected to happen.
Setup
next-transpile-modules
version: 9.0.0npm
/yarn
version: PNPM 6.24.4Additional context Add any other context about the problem here.