Support favicon version 7 (`npm i favicon` will install version 7+)
See original GitHub issueCurrent behaviour π£
Running a webpack build using favicons 7+ will result in
#27 5.123 /node_modules/favicons-webpack-plugin/src/index.js:562
#27 5.123 throw new Error(
#27 5.123 ^
#27 5.123
#27 5.123 Error: Could not find the npm peerDependency "favicons".
#27 5.123 Please run:
#27 5.123 npm i favicons
#27 5.123 - or -
#27 5.123 yarn add favicons
#27 5.123
#27 5.123 Error [ERR_REQUIRE_ESM]: require() of ES Module /node_modules/favicons/dist/index.js from /node_modules/favicons-webpack-plugin/src/index.js not supported.
#27 5.123 Instead change the require of /node_modules/favicons/dist/index.js in /node_modules/favicons-webpack-plugin/src/index.js to a dynamic import() which is available in all CommonJS modules.
#27 5.123 at loadFaviconsLibrary (/node_modules/favicons-webpack-plugin/src/index.js:562:11)
#27 5.123 at FaviconsWebpackPlugin.generateFaviconsWebapp (/node_modules/favicons-webpack-plugin/src/index.js:403:22)
#27 5.123 at FaviconsWebpackPlugin.generateFavicons (/node_modules/favicons-webpack-plugin/src/index.js:315:21)
#27 5.123 at /node_modules/favicons-webpack-plugin/src/index.js:117:18
#27 5.123 at /node_modules/favicons-webpack-plugin/src/cache.js:155:5
#27 5.123 at CacheFacade.providePromise (/node_modules/webpack/lib/CacheFacade.js:337:24)
#27 5.146 error Command failed with exit code 1.
#27 5.146 info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Expected behaviour βοΈ
A normal build
Reproduction Example πΎ
...
"favicons": "^7.0.0-beta.3",
"favicons-webpack-plugin": "^5.0.2",
...
Environment π₯
Node.js v16.14.0
darwin 21.3.0
β βββ favicons-webpack-plugin@5.0.2 deduped
β βββ favicons@7.0.0-beta.3 deduped
β βββ¬ file-loader@6.2.0
β β βββ webpack@5.69.1 deduped
β βββ html-webpack-plugin@5.5.0 deduped
β βββ webpack-cli@4.9.2 deduped
β βββ webpack@5.69.1 deduped
Issue Analytics
- State:
- Created 2 years ago
- Reactions:14
- Comments:9 (1 by maintainers)
Top Results From Across the Web
favicons - npm
Favicon generator for Node.js. Latest version: 7.0.2, last published: 2 months ago. Start using favicons in your project by running `npm i ......
Read more >favicons-webpack-plugin - npm
Let webpack generate all your favicons and icons for you. Latest version: 6.0.0-alpha.1, last published: 21 days ago.
Read more >favicons-ts - npm
Favicon generator for Node.js. Latest version: 6.2.3, last published: a year ago. Start using favicons-ts in your project by running `npm i ......
Read more >@types/favicons - npm
Stub TypeScript definitions entry for favicons, which provides its own types definitions. Latest version: 7.0.0, last published: a month ago.
Read more >react-favicon - npm
React favicon helper. Latest version: 1.0.1, last published: 6 months ago. Start using react-favicon in your project by running `npm iΒ ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

now favicons v7 stable is released. pls make this lib compatible with it. https://github.com/itgalaxy/favicons/releases/tag/v7.0.0
It would really be nice, that we could make use of favicons 7, which does not depend on old version of minimist.