question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot find module 'webpack/lib/RuleSet'

See original GitHub issue

Version

15.4.0

Reproduction link

https://www.npmjs.com/package/vue-loader/v/15.4.2

Steps to reproduce

Init a project without installing webpack locally , and run global webpack in terminal

What is expected?

webpack build successfully

What is actually happening?

Error: Cannot find module ‘webpack/lib/RuleSet’


Due to line 2 in node_modules/vue-loader/lib/plugin.js

const RuleSet = require('webpack/lib/RuleSet')

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:12
  • Comments:17 (2 by maintainers)

github_iconTop GitHub Comments

8reactions
matthew-deancommented, Sep 23, 2020

This happens with the next version of Webpack (Webpack 5.0.0-rc.1)

7reactions
bietkulcommented, Sep 20, 2019

Check this https://github.com/vuejs/vue-loader/issues/1586#issuecomment-528682809 Adding webpack as a dev dependency resolved the issue for me.

Read more comments on GitHub >

github_iconTop Results From Across the Web

node.js - Error: Cannot find module 'webpack/lib/rules ...
I had this error in my project. After searching for it, I discovered that I have to upgrade the Vue loader. And if...
Read more >
[Solved] Error: Cannot find module 'webpack/lib/rules ...
To Solve Error: Cannot find module 'webpack/lib/rules/DescriptionDataMatcherRulePlugin' This error may occur Because of Vue-Loader. If you do ...
Read more >
Cannot find module 'webpack/lib/RuleSet'' error-Vue.js
It sounds like you're missing webpack from your package.json, but it was previously installed. Clearing out your node_modules would also remove it. To...
Read more >
Error: Cannot find module 'webpack/lib/RuleSet' - DCloud问答
uni-app,mui,nativejs,dcloud,HBuilder,HBuilderX,HTML5,流应用,数字天堂网络,数字天堂,web,前端开发,web开发,跨平台,开发工具,ide,css,javascript.
Read more >
Error: Cannot find module 'webpack/lib/RuleSet'的问题解决方法
微信小程序创建好后不能正常运行,报Error: Cannot find module 'webpack/lib/RuleSet'的解决方法_1671465600.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found