Skip to content

Conversation

@joshfoskett
Copy link

@joshfoskett joshfoskett commented Jan 28, 2021

Currently, the regex will match the beginning of the tag (e.g. <mj-image*), instead of looking for an exact match. This works fine if you're using the default MJML components. However, if you have a custom component, like mj-image-variable, it will look for <mj-image*, which means it'll match <mj-image-variable, causing issues.

Current regex:
https://regex101.com/r/OouqpK/1

Updated regex:
https://regex101.com/r/e4fEY6/1/

Currently, the regex will match the beginning of the tag (e.g. `<mj-image*`), instead of looking for an exact match. This works fine if you're using the default MJML components. However, if you have a custom component, like `mj-image-variable`, it will look for `<mj-image*`, which means it'll match `<mj-image-variable`, causing issues.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant