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.

Support favicon version 7 (`npm i favicon` will install version 7+)

See original GitHub issue

Current 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:closed
  • Created 2 years ago
  • Reactions:14
  • Comments:9 (1 by maintainers)

github_iconTop GitHub Comments

6reactions
ximexcommented, Sep 12, 2022

now favicons v7 stable is released. pls make this lib compatible with it. https://github.com/itgalaxy/favicons/releases/tag/v7.0.0

6reactions
synedra-mpecommented, Apr 14, 2022
yarn audit v1.22.17
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ critical      β”‚ Prototype Pollution in minimist                              β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Package       β”‚ minimist                                                     β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Patched in    β”‚ >=1.2.6                                                      β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Dependency of β”‚ favicons                                                     β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ Path          β”‚ favicons > to-ico > resize-img > jimp > mkdirp > minimist    β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ More info     β”‚ https://www.npmjs.com/advisories/1067342                     β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

It would really be nice, that we could make use of favicons 7, which does not depend on old version of minimist.

Read more comments on GitHub >

github_iconTop 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 >

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