1 Star 0 Fork 0

米豆 / hexo-theme-BubbleGum

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
index.js 772 Bytes
一键复制 编辑 原始数据 按行查看 历史
MiMonarchRD 提交于 2021-10-03 09:46 . fix bug
const { deepMerge } = require('hexo-util');
const { sep, join } = require('path');
const { makeRe } = require('micromatch');
const Theme = require(join(hexo.plugin_dir, 'hexo/lib/theme'));
hexo.theme_dir = join(hexo.plugin_dir, 'hexo-theme-bubblegum') + sep;
hexo.theme_script_dir = join(hexo.theme_dir, 'scripts') + sep;
hexo.theme = new Theme(hexo);
const ignored = ['**/node_modules/hexo-theme-*/node_modules/**', '**/node_modules/hexo-theme-*/.git/**'];
hexo.theme.ignore = ignored;
hexo.theme.options.ignored = ignored.map(item => makeRe(item));
// load theme_config before generate
hexo.extend.filter.register('before_generate', () => {
if (hexo.config.theme_config) {
hexo.theme.config = deepMerge(hexo.theme.config, hexo.config.theme_config);
}
}, -999);
1
https://gitee.com/mimonarchrd/hexo-theme-BubbleGum.git
git@gitee.com:mimonarchrd/hexo-theme-BubbleGum.git
mimonarchrd
hexo-theme-BubbleGum
hexo-theme-BubbleGum
main

搜索帮助