diff options
| author | Mitja Felicijan <mitja.felicijan@gmail.com> | 2023-11-01 22:54:27 +0100 |
|---|---|---|
| committer | Mitja Felicijan <mitja.felicijan@gmail.com> | 2023-11-01 22:54:27 +0100 |
| commit | 2417a6b7603524dc5cd30d29b153f91024b9443d (patch) | |
| tree | 9be5ea8e5baba96dd9159217da6badf6157fb595 /_posts/2023-05-01-cachebusting-in-hugo.md | |
| parent | 89ba3497f07a8ea43d209b583f39fcc286acc923 (diff) | |
| download | mitjafelicijan.com-2417a6b7603524dc5cd30d29b153f91024b9443d.tar.gz | |
Move to Jekyll
Diffstat (limited to '_posts/2023-05-01-cachebusting-in-hugo.md')
| -rw-r--r-- | _posts/2023-05-01-cachebusting-in-hugo.md | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/_posts/2023-05-01-cachebusting-in-hugo.md b/_posts/2023-05-01-cachebusting-in-hugo.md new file mode 100644 index 0000000..f8d92b2 --- /dev/null +++ b/_posts/2023-05-01-cachebusting-in-hugo.md | |||
| @@ -0,0 +1,18 @@ | |||
| 1 | --- | ||
| 2 | title: Cache busting in Hugo | ||
| 3 | permalink: /cachebusting-in-hugo.html | ||
| 4 | date: 2023-05-01T12:00:00+02:00 | ||
| 5 | layout: post | ||
| 6 | type: note | ||
| 7 | draft: false | ||
| 8 | tags: [hugo] | ||
| 9 | --- | ||
| 10 | |||
| 11 | ```html | ||
| 12 | \{\{ $cachebuster := delimit (shuffle (split (md5 "6fab11c6669976d759d2992eff1dd5be") "" )) "" \}\} | ||
| 13 | |||
| 14 | <link rel="stylesheet" href="/style.css?v=\{\{ $cachebuster \}\}"> | ||
| 15 | ``` | ||
| 16 | |||
| 17 | This `6fab11c6669976d759d2992eff1dd5be` can be random string you generate use. | ||
| 18 | You can use whatever you want. | ||
