Skip to content

Commit

Permalink
♻️ Refactor: migrate theme js from src to assets by js.build
Browse files Browse the repository at this point in the history
  • Loading branch information
Lruihao committed Aug 3, 2022
1 parent 7c8344e commit 65371a1
Show file tree
Hide file tree
Showing 8 changed files with 7,737 additions and 3,596 deletions.
3 changes: 1 addition & 2 deletions .babelrc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
{
"targets": "> 0.25%, not dead"
}
],
"minify"
]
]
}
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ All notable changes to this project will be documented in this file.
- :bug: Fix: busuanzi logic error
- :bug: Fix: close comment system logic error when the article was expired
- :bug: Style: fix typos for rel attribute value noreferrer (@yureiita[#157](https://github.com/hugo-fixit/FixIt/pull/157))
- :recycle: Refactor: migrate service-worker.js to js.build
- :recycle: Refactor: migrate theme js from src to assets by js.build
- :recycle: Refactor: change the post edit url splicing rules
- :mag: Feat(SEO): add options to make output `baidu_urls.txt` file ([#138](https://github.com/hugo-fixit/FixIt/issues/138))
- :truck: Feat: migrate exampleSite to docs submodule
Expand All @@ -38,6 +38,12 @@ All notable changes to this project will be documented in this file.
- Update Waline from 1.5.2 to 2.6.1
- Update Valine from 1.4.18 to 1.5.0
- Update mermaid from 8.13.3 to 9.1.3
- :arrow_up: Chore(deps-dev):
- Bump babel-preset-minify from 0.5.1 to 0.5.2 ([#145](https://github.com/hugo-fixit/FixIt/pull/145))
- Bump core-js from 3.22.0 to 3.24.1 ([#168](https://github.com/hugo-fixit/FixIt/pull/168))
- Bump @babel/preset-env from 7.16.11 to 7.18.10 ([#169](https://github.com/hugo-fixit/FixIt/pull/169))
- Bump @babel/cli from 7.17.6 to 7.18.10 ([#170](https://github.com/hugo-fixit/FixIt/pull/170))
- Bump @babel/core from 7.17.9 to 7.18.10 ([#171](https://github.com/hugo-fixit/FixIt/pull/171))
- **Full Changelog:** @Lruihao [`v0.2.14...v0.2.15`](https://github.com/hugo-fixit/FixIt/compare/v0.2.14...v0.2.15)

## v0.2.14 [2022.5.15]
Expand Down
1,493 changes: 1,493 additions & 0 deletions assets/js/theme.js

Large diffs are not rendered by default.

3 changes: 0 additions & 3 deletions assets/js/theme.min.js

This file was deleted.

1 change: 0 additions & 1 deletion assets/js/theme.min.js.map

This file was deleted.

3 changes: 1 addition & 2 deletions layouts/partials/assets.html
Original file line number Diff line number Diff line change
Expand Up @@ -250,8 +250,7 @@
{{- $config | jsonify | printf "window.config=%s;" | dict "Content" | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}

{{- /* Theme script */ -}}
{{- dict "Source" "js/theme.min.js" "Fingerprint" $fingerprint "Defer" true | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
{{- $_ := (resources.Get "js/theme.min.js.map").RelPermalink -}}
{{- dict "Source" "js/theme.js" "Minify" true "Fingerprint" $fingerprint "Defer" true | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}

{{- /* Custom script */ -}}
{{- if eq .Site.Params.customJS.enable true -}}
Expand Down
Loading

0 comments on commit 65371a1

Please sign in to comment.