feat: add .webmanifest as json, add .map and .wasm to compressing

This commit is contained in:
wherewhere 2024-12-03 16:41:52 +08:00
parent ac31b9edaa
commit bcaa327494
2 changed files with 14 additions and 3 deletions

View File

@ -177,7 +177,9 @@ minify:
enable: false
include:
- "*.json"
- "*.webmanifest"
- "!*.min.json"
- "!*.min.webmanifest"
```
- **enable** - Enable the plugin. Defaults to `false`.
@ -197,6 +199,8 @@ minify:
- "*.html"
- "*.css"
- "*.js"
- "*.map"
- "*.wasm"
- "*.txt"
- "*.ttf"
- "*.atom"
@ -205,6 +209,7 @@ minify:
- "*.svg"
- "*.eot"
- "*.json"
- "*.webmanifest"
```
- **enable** - Enable the plugin. Defaults to `true`.
@ -226,6 +231,8 @@ minify:
- "*.html"
- "*.css"
- "*.js"
- "*.map"
- "*.wasm"
- "*.txt"
- "*.ttf"
- "*.atom"
@ -234,6 +241,7 @@ minify:
- "*.svg"
- "*.eot"
- "*.json"
- "*.webmanifest"
```
- **enable** - Enable the plugin. Defaults to `true`.
@ -253,6 +261,8 @@ minify:
- "*.html"
- "*.css"
- "*.js"
- "*.map"
- "*.wasm"
- "*.txt"
- "*.ttf"
- "*.atom"
@ -261,6 +271,7 @@ minify:
- "*.svg"
- "*.eot"
- "*.json"
- "*.webmanifest"
```
- **enable** - Enable the plugin. Defaults to `false`.

View File

@ -81,7 +81,7 @@ hexo.config.minify.gzip = {
enable: true,
priority: 10,
verbose: false,
include: ['*.html', '*.css', '*.js', '*.txt', '*.ttf', '*.atom', '*.stl', '*.xml', '*.svg', '*.eot', '*.json', '*.webmanifest'],
include: ['*.html', '*.css', '*.js', '*.map', '*.wasm', '*.txt', '*.ttf', '*.atom', '*.stl', '*.xml', '*.svg', '*.eot', '*.json', '*.webmanifest'],
globOptions: { basename: true },
...hexo.config.minify.gzip
}
@ -90,7 +90,7 @@ hexo.config.minify.brotli = {
enable: true,
priority: 10,
verbose: false,
include: ['*.html', '*.css', '*.js', '*.txt', '*.ttf', '*.atom', '*.stl', '*.xml', '*.svg', '*.eot', '*.json', '*.webmanifest'],
include: ['*.html', '*.css', '*.js', '*.map', '*.wasm', '*.txt', '*.ttf', '*.atom', '*.stl', '*.xml', '*.svg', '*.eot', '*.json', '*.webmanifest'],
globOptions: { basename: true },
...hexo.config.minify.brotli
}
@ -99,7 +99,7 @@ hexo.config.minify.zstd = {
enable: false,
priority: 10,
verbose: false,
include: ['*.html', '*.css', '*.js', '*.txt', '*.ttf', '*.atom', '*.stl', '*.xml', '*.svg', '*.eot', '*.json', '*.webmanifest'],
include: ['*.html', '*.css', '*.js', '*.map', '*.wasm', '*.txt', '*.ttf', '*.atom', '*.stl', '*.xml', '*.svg', '*.eot', '*.json', '*.webmanifest'],
globOptions: { basename: true },
...hexo.config.minify.zstd
}