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.

Webpack 5 support?

See original GitHub issue

Describe the bug If I use stylus-loader@5 in my project, it gives out the error Syntax Error: TypeError: this.getOptions is not a function. From what I found, https://github.com/webpack-contrib/stylus-loader/issues/307 stylus loader requires webpack@5 so I install webpack@5, and another error shows up:

Error: Rule can only have one resource source (provided resource and test + include + exclude) in {
  "exclude": [
    null
  ],
  "use": [...]
}

So I’m not sure if this error relates to this plugin or not? since I saw the dependencies of it is webpack@4. or perhaps I am missing some sort of config?

To Reproduce Using stylus-loader@5 in the project

Expected behavior No error during run/build

Environment (please complete the following information): Just want to update my project https://github.com/lanly-dev/template-electron-vue-ts

Thank you!

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:19 (4 by maintainers)

github_iconTop GitHub Comments

9reactions
nklaymancommented, Aug 28, 2021

Sorry for the delays, was quite busy over the summer. I just started college so I’ll be busy for the next little while, but I hope to have time for this sometime within the next month.

8reactions
nklaymancommented, May 9, 2021

Webpack 5 support will be coming with v3 of this plugin, as it would require breaking changes to implement. I hope to have an alpha out sometime in the next week or so.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Webpack 5 release (2020-10-10)
Webpack 5 adds support for some CommonJs constructs, allows to eliminate unused CommonJs exports and track referenced export names from require ...
Read more >
facebook/create-react-app - Webpack 5 support overview
Overview of tasks needed for updating CRA to Webpack 5 - Some of the work will support both Webpack 4 + 5 but...
Read more >
What's New in Webpack 5 - Frontend Digest
What's new in Webpack 5 · Faster builds with persistent caching · Smaller bundle sizes · Better long term caching · Breaking changes...
Read more >
Webpack 5 Adoption - Next.js
Improved Long Term Caching of Assets: Deterministic code output that is less likely to change between builds; Improved Tree Shaking; Support for assets...
Read more >
Upgrading Webpack 4 → 5 | Square Corner Blog
Webpack 5 Gains · Decreased bundle size by 27-28% · Decreased build time by 10% (2m 54s → 2m 36s) · Cached dev...
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