From a7c242e225f23e68829d45d2a32cfd00cff09b0c Mon Sep 17 00:00:00 2001 From: Martin Sugasti Date: Thu, 7 Sep 2023 00:05:22 +0200 Subject: [PATCH] I had this exact same issue https://github.com/rails/jsbundling-rails/issues/76\#issue-1115571908 Better explained in a later comment https://github.com/rails/jsbundling-rails/issues/76\#issuecomment-1022695521 And I'm trying this solution https://github.com/rails/jsbundling-rails/issues/76\#issuecomment-1051248565 I would have said the solution makes not only images, but also .js and .css lose the fingerprint functionality, but for whatever reason it's still fingerptinting everything except images.. --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 434fb20..58eeb1d 100644 --- a/package.json +++ b/package.json @@ -26,7 +26,7 @@ "slick-carousel": "^1.8.1" }, "scripts": { - "build": "esbuild app/javascript/*.* --bundle --sourcemap --outdir=app/assets/builds --public-path=/assets --loader:.js=jsx --loader:.png=file --loader:.svg=file", + "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", "build:css:compile": "sass ./app/assets/stylesheets/application.bootstrap.scss:./app/assets/builds/application.css --no-source-map --load-path=node_modules", "build:css:prefix": "postcss ./app/assets/builds/application.css --use=autoprefixer --output=./app/assets/builds/application.css", "build:css": "yarn build:css:compile && yarn build:css:prefix",