feat: add build.getPublicHash option#1377
Conversation
Generate a revision hash for each asset in the public directory.
|
I don't know about this. Assets referenced from imports are already auto-hashed. So this means anything under The whole point of |
b03bac6 to
9866e02
Compare
|
I've been using The alternatives are:
|
- ensure JS bundle references to public/ assets are rewritten - add `publicUrls` property to ResolvedConfig - copy public assets before HTML transforms are applied
|
@knightly-bot build this |
|
I would prefer this to be a 3rd party plugin to not break the originally intended usage of |
|
I tried that approach first, but it's not currently possible. If we had a hook for rewriting public filenames (eg: I still think having it built-in is better, since it lets us avoid |
|
Removed the |
Generate a revision hash for each asset in the public directory.
Features
public/assets. Cache forever, effortless "invalidation".checkPublicFilecalls when building, thereby reducing FS calls.