You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 9, 2020. It is now read-only.
simple-html-tokenizer has some problem. First of all, it does not understand HTML and SVG namespace and elements correctly (which makes us to expand self-closing tag manually via regex)
Secondly, it just gives array of parsed tag sequence rather than structured object. This makes code quite verbose (which I did not realize at first use)
simple-html-tokenizer is pretty fast and lightweight but we need parser with better output.
The text was updated successfully, but these errors were encountered:
How about using SVGO instead of the custom code? There are loaders for SVGO but I don't think I have been able to find any that inline the SVG for you and is platform-independent (i.e. you could use on React or Vue).
@ianwalter I believe you can use svgo-loader + raw-loader to have almost same, or better effect this loader gives. In fact svg inlining is pretty much nothing but pasting contents into a webpack module (which raw-loader does). For the matter of fact, this loader should work platform-independent either. I built this loader for lower install overhead because svgo-loader (or svgo) has a bit huge for small tasks.
simple-html-tokenizer
has some problem. First of all, it does not understand HTML and SVG namespace and elements correctly (which makes us to expand self-closing tag manually via regex)Secondly, it just gives array of parsed tag sequence rather than structured object. This makes code quite verbose (which I did not realize at first use)
simple-html-tokenizer is pretty fast and lightweight but we need parser with better output.
The text was updated successfully, but these errors were encountered: