1
0
Fork 0
forked from OpenNeo/impress

Fix precompile error by removing unneeded minify

Oh right, Rails does its own terser minification step, so using esbuild's minifier is just running two minifiers, which is just asking for trouble!

For some reason, running it this time on the non-Vagrant box, terser was crashing trying to read something in the minified item-page.js. Now that we don't minify, that fixes it, and the output is still minified by the end!

I do notice though that --minify does some other stuff in esbuild that I forget all of what it is. Oh well, not gonna worry about it for now!
This commit is contained in:
Emi Matchu 2023-09-13 17:31:38 -07:00
parent 8bd7ca167c
commit 1f68829b15

View file

@ -27,8 +27,7 @@
"tweenjs": "^1.0.2"
},
"scripts": {
"build": "yarn build:base --minify",
"build:base": "esbuild app/javascript/*.* --bundle --sourcemap --outdir=app/assets/builds --public-path=/assets --asset-names=[name]-[hash].digested --loader:.js=jsx --loader:.png=file --loader:.svg=file --loader:.min.js=text",
"dev": "yarn build:base --watch --public-path=/dev-assets"
"build": "esbuild app/javascript/*.* --bundle --sourcemap --outdir=app/assets/builds --public-path=/assets --asset-names=[name]-[hash].digested --loader:.js=jsx --loader:.png=file --loader:.svg=file --loader:.min.js=text",
"dev": "yarn build --watch --public-path=/dev-assets"
}
}