-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
jsc.minify.format.inlineScript support #7602
Comments
FWIW, the Terser implementation isn't complete, so the linked code isn't sufficient to make it completely safe. I've filed an issue with Terser: terser/terser#1408 |
I'm implementing this with a simple lookup of the latest printed stuff before printing. For example I'm going to check if the output stream ends with "--" before printing the ">" operator. If it does, I'll add a space. |
It looks like #8252 tried to fix this, but it doesn't seem to actually work. I haven't dug deep into why, but at least in my use case I'm using swc as the minifier in a webpack build, where pre-minification it's got |
This closed issue has been automatically locked because it had no new activity for a month. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you. |
Describe the feature
https://swc.rs/docs/configuration/minification#jscminifyformat
input:
expected output:
Are you willing to work on this yourself?
yes
Babel plugin or link to the feature description
https://github.com/terser/terser/blob/aeddfabd04ace5a6565b2920b074ad7dc210bcac/lib/output.js#L367
Additional context
No response
The text was updated successfully, but these errors were encountered: