How to minify JS and ignore errors #700
-
I have a need to minify JS but ignore any errors it may kick up. Risky, sure. Is that possible? I set "Check syntax with" to nothing but no joy, still picks up the errors. I started looking through the Eslint settings - daunting. To give some reasoning without too much derailing detail: I need to use some Laravel @can directives around some JS built buttons for a datatables table. The pipeline is the JS gets squished into a blade.php file and embedded/included into the Laravel view. So those @can directives are parsed out at runtime. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
No, that isn't possible. If the minifier is throwing errors, that means it can't correctly parse the JS you're trying to minify, which means it can't create minified JS. There is no way to take JS-with-errors and turn it into minified-JS-with-errors. |
Beta Was this translation helpful? Give feedback.
No, that isn't possible. If the minifier is throwing errors, that means it can't correctly parse the JS you're trying to minify, which means it can't create minified JS. There is no way to take JS-with-errors and turn it into minified-JS-with-errors.