Skip to content

Commit

Permalink
more docs
Browse files Browse the repository at this point in the history
  • Loading branch information
gurgunday committed Feb 3, 2024
1 parent 720629a commit a11247b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ Default: `undefined`

To enable `hash`, the `wildcard` option must first be disabled explicitly. 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 and the cache will bust for that asset.

**Note:** A custom script can be used to generate the hashes in advance, ideally during the build phase.
**Note:** A custom script can be used to generate the hashes in advance to speed up cold start times, ideally during the build phase.

##### Example:

Expand Down Expand Up @@ -260,6 +260,8 @@ async function run () {
run()
```

The hashes are created in the following directory: `.tmp/hashes.json`.

#### `allowedPath`

Default: `(pathName, root, request) => true`
Expand Down

0 comments on commit a11247b

Please sign in to comment.