jquery's append not working with svg element?

后端 未结 14 2216
北海茫月
北海茫月 2020-11-21 06:28

Assuming this:



 
 

        
14条回答
  •  天涯浪人
    2020-11-21 06:58

    A much simpler way is to just generate your SVG into a string, create a wrapper HTML element and insert the svg string into the HTML element using $("#wrapperElement").html(svgString). This works just fine in Chrome and Firefox.

提交回复
热议问题