Javascript Error Inline SVG
-
Recently this plugin has started throwing some javascript errors in the console when trying to use the inline svgs. I am getting the error message “Uncaught TypeError: Cannot read property ‘endsWith’ of undefined at Object.<anonymous> (svgs-inline.js?ver=1.0.0:63)”
This relates to this call `if (!imgURL.endsWith(‘svg’)) {
return;
}`It would appear that the $target variable set above this section is not getting the correct data and none of the img variables wind up being defined.
Changing the target to simply ‘img.style-svg’ clears the error, but that removes the option to select your own class etc.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
The topic ‘Javascript Error Inline SVG’ is closed to new replies.