Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

using to replace existing elements without src attr #45

Open
robbyking3 opened this issue Apr 19, 2016 · 2 comments
Open

using to replace existing elements without src attr #45

robbyking3 opened this issue Apr 19, 2016 · 2 comments

Comments

@robbyking3
Copy link

In our app we are using <span class="icon icon-name"></span> with an icon font. I was thinking of trying to switch over to using SVGs and thus came here.

For our current structure is it possible to let it remain as it is, but then I would map the class names to their corresponding SVGs and replace them using SVGInjector?

Great work on this btw.

Cheers

@markadrake
Copy link

I'd break up these responsibilities.

Use JavaScript to find your .icon elements and tag on the data-src attribute. Then initialize the SVGInjector. I think that would work no?

@robbyking3
Copy link
Author

ah yeah, that might work. I'll try it out. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants