mirror of https://github.com/curbengh/hexo-yam
refactor: use basename instead of matchBase
This commit is contained in:
parent
7d06de7e79
commit
43a316d149
12
index.js
12
index.js
|
@ -17,7 +17,7 @@ if (hexo.config.neat_enable === true) {
|
||||||
removeStyleLinkTypeAttributes: true,
|
removeStyleLinkTypeAttributes: true,
|
||||||
minifyJS: true,
|
minifyJS: true,
|
||||||
minifyCSS: true,
|
minifyCSS: true,
|
||||||
globOptions: { matchBase: true }
|
globOptions: { basename: true }
|
||||||
}, hexo.config.neat_html)
|
}, hexo.config.neat_html)
|
||||||
|
|
||||||
// CSS minifier
|
// CSS minifier
|
||||||
|
@ -26,7 +26,7 @@ if (hexo.config.neat_enable === true) {
|
||||||
logger: false,
|
logger: false,
|
||||||
exclude: ['*.min.css'],
|
exclude: ['*.min.css'],
|
||||||
level: 2,
|
level: 2,
|
||||||
globOptions: { matchBase: true }
|
globOptions: { basename: true }
|
||||||
}, hexo.config.neat_css)
|
}, hexo.config.neat_css)
|
||||||
|
|
||||||
// Javascript minifier
|
// Javascript minifier
|
||||||
|
@ -37,7 +37,7 @@ if (hexo.config.neat_enable === true) {
|
||||||
compress: {},
|
compress: {},
|
||||||
mangle: true,
|
mangle: true,
|
||||||
output: {},
|
output: {},
|
||||||
globOptions: { matchBase: true }
|
globOptions: { basename: true }
|
||||||
}, hexo.config.neat_js)
|
}, hexo.config.neat_js)
|
||||||
|
|
||||||
// SVG minifier
|
// SVG minifier
|
||||||
|
@ -46,7 +46,7 @@ if (hexo.config.neat_enable === true) {
|
||||||
logger: false,
|
logger: false,
|
||||||
include: ['*.svg', '!*.min.svg'],
|
include: ['*.svg', '!*.min.svg'],
|
||||||
plugins: [],
|
plugins: [],
|
||||||
globOptions: { matchBase: true }
|
globOptions: { basename: true }
|
||||||
}, hexo.config.neat_svg)
|
}, hexo.config.neat_svg)
|
||||||
|
|
||||||
// gzip compression
|
// gzip compression
|
||||||
|
@ -54,7 +54,7 @@ if (hexo.config.neat_enable === true) {
|
||||||
enable: true,
|
enable: true,
|
||||||
logger: false,
|
logger: false,
|
||||||
include: ['*.html', '*.css', '*.js', '*.txt', '*.ttf', '*.atom', '*.stl', '*.xml', '*.svg', '*.eot', '*.json'],
|
include: ['*.html', '*.css', '*.js', '*.txt', '*.ttf', '*.atom', '*.stl', '*.xml', '*.svg', '*.eot', '*.json'],
|
||||||
globOptions: { matchBase: true }
|
globOptions: { basename: true }
|
||||||
}, hexo.config.neat_gzip)
|
}, hexo.config.neat_gzip)
|
||||||
|
|
||||||
// brotli compression
|
// brotli compression
|
||||||
|
@ -62,7 +62,7 @@ if (hexo.config.neat_enable === true) {
|
||||||
enable: true,
|
enable: true,
|
||||||
logger: false,
|
logger: false,
|
||||||
include: ['*.html', '*.css', '*.js', '*.txt', '*.ttf', '*.atom', '*.stl', '*.xml', '*.svg', '*.eot', '*.json'],
|
include: ['*.html', '*.css', '*.js', '*.txt', '*.ttf', '*.atom', '*.stl', '*.xml', '*.svg', '*.eot', '*.json'],
|
||||||
globOptions: { matchBase: true }
|
globOptions: { basename: true }
|
||||||
}, hexo.config.neat_brotli)
|
}, hexo.config.neat_brotli)
|
||||||
|
|
||||||
const filter = require('./lib/filter')
|
const filter = require('./lib/filter')
|
||||||
|
|
Loading…
Reference in New Issue