3 ms·
You're saying you can embed all the SVGs onto one page, and then reference them on other pages/domains by using xlink.href? I haven't heard of this? So what yo
by nikkwong 6y ago
You're saying you can embed all the SVGs onto one page, and then reference them on other pages/domains by using xlink.href? I haven't heard of this?
So what you're describing is having site.com/page1 which has markup:
<body>
<svg id="icon-1">
...
</svg>
</body>
and then on site.com/page2 having
<body>
<svg>
<use href="/page1#icon-1">
</svg>
</body>
Or something of this manner? Haven't encountered this, but sounds awesome; especially since you'd get the power of both inlining and caching the asset.