简体   繁体   中英

SVG images are not showing in reactjs

i want to create svg shapes dynamically and append it to dom using react here is the jsfiddle link

Svg shapes are not displaying in react

If the goal is to draw a cat then the problem is that your d: properties is full of new lines thus making it not being a valid SVG path.

Check your console and you'll see the error Uncaught SyntaxError: embedded: Unterminated string constant .

Fiddle Demo

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM