Skip to content
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

Next.js issue with latest version - ERR_MODULE_NOT_FOUND #257

Closed
moljac024 opened this issue Dec 18, 2024 · 7 comments · Fixed by #258
Closed

Next.js issue with latest version - ERR_MODULE_NOT_FOUND #257

moljac024 opened this issue Dec 18, 2024 · 7 comments · Fixed by #258
Assignees

Comments

@moljac024
Copy link

> next build

  ▲ Next.js 14.2.15
  - Environments: .env

 ✓ Linting and checking validity of types    
   Creating an optimized production build ...
 ✓ Compiled successfully
unhandledRejection Error [ERR_MODULE_NOT_FOUND]: Cannot find module '/home/bojan/projects/mind-central/web/node_modules/lodash/debounce' imported from /home/bojan/projects
/mind-central/web/node_modules/react-resize-detector/build/utils.js
Did you mean to import "lodash/debounce.js"?
    at finalizeResolution (node:internal/modules/esm/resolve:257:11)
    at moduleResolve (node:internal/modules/esm/resolve:914:10)
    at defaultResolve (node:internal/modules/esm/resolve:1038:11)
    at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:554:12)
    at ModuleLoader.resolve (node:internal/modules/esm/loader:523:25)
    at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:246:38)
    at ModuleJob._link (node:internal/modules/esm/module_job:126:49) {
  type: 'Error',
  code: 'ERR_MODULE_NOT_FOUND',
  url: 'file:///home/bojan/projects/mind-central/web/node_modules/lodash/debounce'
}
@moljac024 moljac024 changed the title Next.js issue with latest version Next.js issue with latest version - ERR_MODULE_NOT_FOUND Dec 18, 2024
@snelsi
Copy link
Collaborator

snelsi commented Dec 18, 2024

May you try upgrading to 12.0.2-beta.0 please?

npm i react-resize-detector@12.0.2-beta.0

@snelsi snelsi self-assigned this Dec 18, 2024
@cewald
Copy link

cewald commented Dec 18, 2024

Had the same issue and it is working again with v12.0.2-beta.0

@chenbolan
Copy link

I have encountered a similar problem. Will we have an official release soon to fix this issue?

@snelsi
Copy link
Collaborator

snelsi commented Dec 30, 2024

@chenbolan
Please try upgrading to 12.0.2-beta.0 and tell if it fixes the issue for you

npm i react-resize-detector@12.0.2-beta.0

@chenbolan
Copy link

@snelsi 12.0.2-beta.0 can fix my issue, but our project does not allow the use of beta version dependencies. So I wonder if we will have an official release to fix this issue?thanks.

@snelsi
Copy link
Collaborator

snelsi commented Dec 30, 2024

I will push a release version, just need a confirmation it actually works

@KrzysztofKarol
Copy link

KrzysztofKarol commented Dec 31, 2024

12.0.2-beta.0 fixes my issue too

12.0.1:

⨯ [Error: Cannot find module '/repo/node_modules/lodash/debounce' imported from /repo/node_modules/react-resize-detector/build/utils.js
Did you mean to import "lodash/debounce.js"?] {
  code: 'ERR_MODULE_NOT_FOUND',
  url: 'file:///repo/node_modules/lodash/debounce',
  page: '/'
}

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

Successfully merging a pull request may close this issue.

5 participants