etagere
etagere copied to clipboard
Feature to hide `dump_svg`/`dump_into_svg`?
A lot of crates depending on this crate probably won't use dump_svg
or dump_into_svg
, so it would be great if we could remove this dependency by default and still have a way to opt-in (e.g. with a svg
feature or similar).
I'd be happy to PR this if that sounds good.
Hi, sorry for the delay I've been away from computers for a couple of weeks.
svg_fmt
is a very tiny dependency, it should not affect build times significantly and since there's no polymorphism at play the compiler has a very easy time not inculding the dumping code into the binary if it isn't used.
Unless you have evidence that build times or release binary sizes are noticeably affected I would prefer to keep it without feature gate for simplicity's sake.
No problem!
I'm targeting WebAssembly, so the concern is mostly about binary size and generally avoiding any extra dependencies. I'll check whether it's included into the final binary – maybe it's already being eliminated during build/linking like you mentioned.