Closed seiyab closed 11 months ago
html-inline-script-webpack-plugin probably handles it like this:
(asset.source() as string).replace(/(<)(\/script>)/g, '\\x3C$2')
Would you be willing to make a minimum reproducible example of this bug?
OK, I will. Which do you prefer?
window.alert("</script>")
The more practical one with a minimal React example. Also, note that the code has been significantly reworked in v1.3.1, so try upgrading first.
@seiyab this should now be fixed as of v1.3.2. Thank you for your bug report! Let me know if you have any other issues.
I confirmed v1.3.2 works fine 👍 🎉 🥇
Hi. Trying to this interesting and useful plugin, I found inlining scripts that contains
</script>
enexpectedly closes script tag.Adding a context, I'm trying to bundle React application into a single HTML. React (probably react-dom) contains
div.innerHTML = "<script></script>";
, at least as of 18.2.0.