Open
Description
Is your feature request related to a problem? Please describe.
- For icon libraries like lucide, the best option is to directly inline the SVG
- I want to do this by
npm i -D lucide-static
andinclude_html!("node_modules/lucide-static/icons/menu.svg")
- This wont work as there is a HTML comment in the view, i.e.
<!-- @license lucide-static v0.503.0 - ISC -->
Describe the solution you'd like
include_html
which strips HTML comments.
Describe alternatives you've considered
- The view macro itself supports HTML comments
- include_view strips out html comments if a second argument is provided
Additional context
- Icon libraries that try to make each icon into components have heavy compile times, embed macros are better IMO
- A generic embed macro would be pretty good, though alternatively this being a separate library might work for lucide / icons specifically
- Also wrt
include_view
it is likely the file types of these files would be HTML or SVG for formatting, so it probably makes sense to strip out the HTML comments there by default?