interweave
interweave copied to clipboard
Add option to disable interleaving for some matchers
I found out a problem with a scenario when two matchers are conflicting. One example is when I'm matching for underscores and the UrlMatcher is matching for URLs which can include underscores.
https://github.com/milesj/interweave/blob/master/packages/emoji-picker/tests/__snapshots__/Emoji.test.tsx.snap
Two links are generated and in between one part is italic.
and when I change the order just one link is generated but it's still italic:

It would be helpful if there would be an option to disable interleaving for specific matchers. For classes it would be great to have them in the constructor options and for the objects inside the MatcherInterface.