chore(theme): update revision
parent
e07001a089
commit
d378cea85f
|
@ -120,12 +120,12 @@ widgets:
|
||||||
position: right
|
position: right
|
||||||
# Other plugin settings
|
# Other plugin settings
|
||||||
plugins:
|
plugins:
|
||||||
|
# Enable page animations
|
||||||
|
animejs: true
|
||||||
# Enable the lightGallery and Justified Gallery plugins
|
# Enable the lightGallery and Justified Gallery plugins
|
||||||
gallery: true
|
gallery: true
|
||||||
# Enable the Outdated Browser plugin
|
# Enable the Outdated Browser plugin
|
||||||
outdated-browser: true
|
outdated-browser: true
|
||||||
# Enable page animations
|
|
||||||
animejs: true
|
|
||||||
# Enable the MathJax plugin
|
# Enable the MathJax plugin
|
||||||
mathjax: true
|
mathjax: true
|
||||||
back-to-top: true
|
back-to-top: true
|
||||||
|
|
|
@ -11,7 +11,7 @@ function replaceWithBundled(html) {
|
||||||
const $ = cheerio.load(html, { decodeEntities: false });
|
const $ = cheerio.load(html, { decodeEntities: false });
|
||||||
$('script').each(function () {
|
$('script').each(function () {
|
||||||
const url = $(this).attr('src');
|
const url = $(this).attr('src');
|
||||||
if (url && url.startsWith(urlFor('/js')) && url.endsWith('.js')) {
|
if (url && url.startsWith(urlFor('/js')) && url.endsWith('.js') && !url.includes('animation')) {
|
||||||
$(this).remove();
|
$(this).remove();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -29,7 +29,7 @@ function replaceWithBundled(html) {
|
||||||
hexo.extend.generator.register('bundle.js', function (locals) {
|
hexo.extend.generator.register('bundle.js', function (locals) {
|
||||||
const folder = path.join(root, 'js');
|
const folder = path.join(root, 'js');
|
||||||
const concated = fs.readdirSync(path.join(root, 'js'))
|
const concated = fs.readdirSync(path.join(root, 'js'))
|
||||||
.filter(filename => filename.endsWith('.js'))
|
.filter(filename => filename.endsWith('.js') && !filename.includes('animation'))
|
||||||
.map(filename => fs.readFileSync(path.join(folder, filename)))
|
.map(filename => fs.readFileSync(path.join(folder, filename)))
|
||||||
.join('\n');
|
.join('\n');
|
||||||
const result = UglifyJS.minify(concated);
|
const result = UglifyJS.minify(concated);
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 8c356afb62f9253b1ec5267e101357ea23688972
|
Subproject commit a785bd3b847bb1fc939a3e264dcfa98088b73871
|
Loading…
Reference in New Issue