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.
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, likemj-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/