gorm.io icon indicating copy to clipboard operation
gorm.io copied to clipboard

[Hexo] Update the website to run with latest node version

Open dumindu opened this issue 2 years ago • 0 comments

I tried to create a PR but I am not sure about the changes I have to done on package.json exactly. However Hexojs/site has been updated and swig templates have been replaced with njk. So, we can run the website with the latest node version now.

  • Rename themes/navy/layout .swig templates to .njk.
  • themes/navy/layout/partial/footer.njk : moment(Date.now()).year() -> moment().year()
  • lang selector in header and mobile nav {% for lang in site.data.languages %} -> {% for lang, value in site.data.languages %} and use lang instead loop.key
  • In package.json can use Hexo "version": "6.1.0"
"hexo": "hexojs/hexo",
"hexo-deployer-git": "3.0.0",
"hexo-fs": "^3.1.0",

and

"engines": {
    "node": ">=12.9.0"
  }
  • README.md need to be updated because now no need to install hexo-cli globally.
  • May be, we can remove yarn.lock and package-lock.json . Use pnpm install

Thanks. Keep up the good work :)

dumindu avatar Mar 15 '22 13:03 dumindu