PolymerElements / iron-iconset-svg

Represents a source of icons expressed as a collection of inline SVGs
https://www.webcomponents.org/element/PolymerElements/iron-iconset-svg
37 stars 34 forks source link

How can i use <symbol> instead of <g>? #18

Closed cbfranca closed 8 years ago

cbfranca commented 8 years ago

I'm trying to define my iconset-svg using symbol instead of g but isn't working. The icon isn't rendered. If i define some icon using it works.

The code:

<iron-iconset-svg name="br-icons">
  <svg style="display: none">
    <defs>    
        <symbol id="icon-menu" viewBox="0 0 1024 1024">
        <title>menu</title>
        <path class="path1" d="M64 192h896v192h-896zM64 448h896v192h-896zM64 704h896v192h-896z"></path>
      </symbol>
 </defs>
</svg>
</iron-iconset-svg>
 <iron-icon icon="br-icons:icon-menu"></iron-icon>

Some idea?

Tks

cbfranca commented 8 years ago

The answer

http://stackoverflow.com/questions/31690176/how-can-i-use-symbol-instead-of-g