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

v1-beta nextjs example - run dev fails - Error: Cannot find module 'webpack' #11309

Closed
Paddy-Hamilton opened this issue May 10, 2018 · 4 comments
Labels
status: waiting for author Issue with insufficient information

Comments

@Paddy-Hamilton
Copy link

I am trying to run the nextjs example
I have just cloned the repo and run npm install in the nextjs example file then try running npm run dev and I get Error: Cannot find module 'webpack';

Webpack is in the node_modules so not sure whats going on

The example is using next v6, I have been reading a few threads (#4227,#4239) which talk about migration from next v5 - v6 causing issues and they all seem related to babel. I don't seem to be getting the same error so not sure they are related.

Your Environment

package.json

{
  "name": "nextjs",
  "version": "1.0.0",
  "private": true,
  "dependencies": {
    "jss": "^9.8.1",
    "material-ui": "^1.0.0-beta.47",
    "next": "^6.0.0",
    "prop-types": "^15.6.1",
    "react": "^16.3.2",
    "react-dom": "^16.3.2",
    "react-jss": "^8.4.0",
    "webpack": "^4.8.1"
  },
  "scripts": {
    "dev": "next",
    "build": "next build",
    "start": "next start"
  }
}

bable.rc

{
  "presets": ["next/babel"]
}

Any help greatly appreciated 😄

@oliviertassinari oliviertassinari added the status: waiting for author Issue with insufficient information label May 10, 2018
@oliviertassinari
Copy link
Member

oliviertassinari commented May 10, 2018

@Paddy-Hamilton I have just tried our nextjs example. It's working fine with Next 6. You will find better help on Next.js. I don't think it's Material-UI related.

@Paddy-Hamilton
Copy link
Author

@oliviertassinari Thanks for getting back to me, could you let me know what version of node you are running?

@oliviertassinari
Copy link
Member

oliviertassinari commented May 10, 2018

node v10.0.0

@lorensr
Copy link
Contributor

lorensr commented Aug 17, 2018

@Paddy-Hamilton did you ever solve this? I'm seeing the same error, with node 6 and node 10.

Also, matching issues:

vercel/next.js#4781
#10439

@lorensr lorensr mentioned this issue Aug 17, 2018
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: waiting for author Issue with insufficient information
Projects
None yet
Development

No branches or pull requests

3 participants