Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

开发环境: 迁移到Webpack 5 #84

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

AnClark
Copy link

@AnClark AnClark commented Sep 24, 2021

介绍

从上古的开发环境迁移到最新的Webpack,截至2021年9月。

在Node.js 14.17.6 LTS上编译成功。

主要变更

  • 更改Webpack配置文件及其依赖,使其适应5.x语法
  • 升级package.json相关依赖(尤其是Babel、node-sass)到最新版本
  • 升级Babel配置文件,以适应7.x版本

测试方法

git clone -b BRANCH https://github.com/USER/hexo-theme-yilia-plus.git
cd hexo-theme-yilia-plus
npm install
npm run dist

注意

只在Node.js LTS 测试成功,最新版16.x疑似无法正确编译node-sass。

Screenshots

Pull request tasks

  • Add test cases for the changes.
  • Passed the CI test.

从上古的开发环境迁移到最新的Webpack,截至2021年9月。

在Node.js 14.17.6 LTS上编译成功。
修复之前,由于路径后会多一个"/",致使跳转不到真正的类别页面路径。
使用url_for函数获取相应的地址,并去掉尾部的"/",有效解决此问题。
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant