-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot read property toSvg #443
Comments
Could you make a CodePen to reproduce this error? Here's a Feather CodePen template to get you started: https://codepen.io/pen?template=WOJZdM |
I've had the same trouble when I tried to set the data-feather attribute dynamically in a php template:
Weird enough the dynamic replacement worked but all subsequent icons didn't render and throw this error. |
I have the same error here, but in my case i'm using Wordpress. When i put a feather icon in the_content() section i'm getting this error. |
This happens when the attribute data-feather is empty or when the icon doesn't exist.. This should be fixed, because an empty or invalid icon name causes all icons to be NOT displayed |
we just need an if statement before rendering? To check if there is that icon? |
I have the same issue it's appear if you are not auth on your website and browse as guest
|
@gamefanpage Does it appear with empty icon names or always ? Sent with GitHawk |
Hi, I encountered the same issue. What happened in my case was I mistyped one icon name ( To reproduce, here's the edited code from the codepen template above: https://codepen.io/kedomingo/pen/pogbLya |
This happens when you put in a non-existing icon name or you misspelt an icon name. |
If fixed this issue in ANGULAR 10 Here is my code :
component.ts
Here key element is |
This was the problem in my case. |
In my case it was icon name typo. Check if icon name exists. |
You can use [attr.data-feather]="dat.key" instaed of [data-feather]="dat.key". |
Same Problem here... checked typo, checked path... the icon with the given address can be loaded by my browser but feather reports the same error...
|
My problem was I fired a multi-rename in my IDE, and I accidentally updated an icon's name to a non existing one. Add these lines to console.log(_icons2.default[name]);
console.log(name);
console.log('-----'); of course delete them after you end debugging. |
The issue here is that's it's very hard to debug, if you have a lot of icons in your page. So far I use this code every time this issue appears, and then manually check against the website to see which icon is misspelled. Can we have a more graceful fallback that doesn't just ruin all the other icons.
|
Getting the following error, any idea's?
The text was updated successfully, but these errors were encountered: