heroicon
heroicon copied to clipboard
[Proposal] Are you open to a top-level `class:` attribute?
Hey 👋
Thanks for the wonderful gem.
I used inline_svg
a lot and one thing that this is different from that (and from regular Rails tag helpers) is that the class
option is nested inside the options
... option.
Would you be open to a PR that would add the class
attribute top-level? That would make it more inline with all the Rails tag helpers.
Thanks!
# Present
heroicon "map-pin", options: {class: "h-4"}
# Proposed API
heroicon "map-pin", class: "h-4"
CC @bharget 👆
+1
since I also can put stroke-width
like this:
heroicon "map-pin", options: { class: "h-5 w-5", stroke_width: 2 }
There's no point of having both options: {}
and path_options: {}
friendly ping @bharget