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
Thanks for a great (and greatly implemented) addon!
I have a request that will be familiar to anybody working with Angular. Angular adds a lot of attributes of its own into generated markup, like this:
Would it be possible to add a feature that would filter out an array of markup attributes by regex? So that we could strip out any attribute that begins from _ng or ng- and thus have a clean markup, leaving the Storybook consumers with all the parts that are really important.
The text was updated successfully, but these errors were encountered:
Sounds like a good idea. Depending on your reason for showing HTML to the user it would be nice to decide exactly what attributes to hide yourself, like you suggest. I think we should add a parameter that filters all attributes and that can be set to either a blacklist array of strings, a regex or a filter function (that could also receive the tag name and attribute value for more advanced filtering).
yes, that’s exactly what i meant 🙂 The regex feature for attribute names would be something that is definitely needed, since at least Angular generates quite random names.
Thanks for a great (and greatly implemented) addon!
I have a request that will be familiar to anybody working with Angular. Angular adds a lot of attributes of its own into generated markup, like this:
Would it be possible to add a feature that would filter out an array of markup attributes by regex? So that we could strip out any attribute that begins from
_ng
orng-
and thus have a clean markup, leaving the Storybook consumers with all the parts that are really important.The text was updated successfully, but these errors were encountered: