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 destructure property `tagName` of 'undefined' or 'null'

See original GitHub issue

Current behaviour 💣

I get the error when I build my project

TypeError: Cannot destructure property `tagName` of 'undefined' or 'null'  

210541614095064

Expected behaviour ☀️

It should be built without any errors.

I want to fine-tune which icons to use in the project.

favicons: [
  "favicon-16x16.png",
  "favicon.ico"
]

But it doesn’t work if I remove the default elements from the array. Or it only works with the inject: false option.

Reproduction Example 👾

https://codesandbox.io/s/tender-jones-obesr?file=/webpack.config.js

Environment 🖥

Node.js v10.23.0
linux 5.4.0-40-generic
+-- favicons@6.2.1
+-- favicons-webpack-plugin@5.0.1
| `-- html-webpack-plugin@5.2.0  deduped
+-- html-webpack-plugin@5.2.0
+-- webpack@5.24.0
`-- webpack-cli@4.5.0

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
code1x1commented, Mar 30, 2021

could you backport the bugfix to favicons-webpack-plugin@4 @jantimon

2reactions
jantimoncommented, Feb 24, 2021

Released in favicons-webpack-plugin@5.0.2

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot destructure property `obj1` of 'undefined' or 'null'
I'm trying to do destructuring in function parameters but I'm getting an error like below, TypeError: Cannot destructure property obj1 of ' ...
Read more >
Fix Cannot Set Property of Null Error in JavaScript - YouTube
Check us out at https://www.skillforge.com The " cannot set property of null " error is a very common JavaScript issue that you may...
Read more >
ember test throw error - Cannot read property 'tagName' of ...
i have migrated ember 3.16 to 3.24 I struck on ember test error. But the app works fine Chrome 88.0 - [17 ms]...
Read more >
[SOLVED] Moralis Streams Error Processing Data
Hey guys, I am trying to destructure the Moralis stream using the following function: export function parseEventData(req: any) { try { const ...
Read more >
Uncaught TypeError: Cannot read property of undefined
Out of the six primitive types defined in JavaScript, namely boolean, string, symbol, number, Null, and undefined, no other type throws as ...
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