less-than-slash
less-than-slash copied to clipboard
Support JSX spread property syntax
In jsx you can use the spread property syntax {...object}
in place of a property-value pair in a tag. less-than-slash was skipping any tags that had this.
This adds support in the xml parser.
I'm getting concerned that maybe our regex is getting too complicated, but I don't know if it's actually causing any performance issues so it should be okay for now (Maybe JSX should get its own parser? Add a JSX option to the settings?). I changed the xmlparser test so that it checks that there is a (potential) whole tag before executing the more complex regex in the parse function. Not sure how much benefit this is.
@mrhanlon review?