Skip to content

Commit

Permalink
improve readme
Browse files Browse the repository at this point in the history
  • Loading branch information
gurgunday committed Feb 3, 2024
1 parent a06f496 commit 3a5b9e9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -198,9 +198,9 @@ with `ignoreTrailingSlash` set to `true`.

Default: `undefined`

To enable `hash`, you must first disable the `wildcard` option. When enabled, `hash` lets the user access assets dynamically using the decorated `getHashedAsset` function. This in turn makes possible the usage of a very high `maxAge` so that the content can be cached as long as possible. If any modifications are made to a file, its hash will simply be recalculated during the next startup (or after running `npm run hash:build <rootList> <serveDotfiles?> <ignoreList>`) and the cache will bust for that asset.
To enable `hash`, you must first disable the `wildcard` option. When enabled, `hash` lets the user access assets dynamically using the decorated `getHashedAsset` function. This in turn makes possible the usage of a very high `maxAge` so that the content can be cached as long as possible. If any modifications are made to a file, its hash will simply be recalculated during the next startup (or after running `npm run hash <rootList> <serveDotfiles?> <globIgnoreList>`) and the cache will bust for that asset.

**Note:** Once you generate the hashes using the `hash:build` script, you need to make sure it's rerun after each file modification.
**Note:** Once you generate the hashes using the `npm run hash` script, you need to make sure it's rerun after each file modification.

#### Example:

Expand Down

0 comments on commit 3a5b9e9

Please sign in to comment.