🐛 Fix: disabled total word count feature to avoid scratch concurrency issues (#124)

This commit is contained in:
Cell
2022-05-02 12:51:04 +08:00
parent bde37f4d55
commit 3d918ae0be
4 changed files with 6 additions and 3 deletions
+1 -1
View File
@@ -18,7 +18,7 @@ All notable changes to this project will be documented in this file.
- :sparkles: Feat: link shortcode add `external-icon` option ([#96](https://github.com/Lruihao/FixIt/issues/96))
- :sparkles: Feat: add GitHub Corners support ([#106](https://github.com/Lruihao/FixIt/issues/106))
- :sparkles: Feat: add local avatar and gravatar support for post author ([#125](https://github.com/Lruihao/FixIt/issues/125))
- :sparkles: Feat: add total word count support in footer ([#124](https://github.com/Lruihao/FixIt/issues/124))
- :sparkles: Feat: add ~~total word count support in footer~~ ([#124](https://github.com/Lruihao/FixIt/issues/124))
- :sparkles: Feat: add "Edit this page" button support ([#103](https://github.com/Lruihao/FixIt/issues/103))
- :sparkles: Feat: add count badge for taxonomy ([#122](https://github.com/Lruihao/FixIt/issues/122))
- :zap: Perf: add Gravatar config support
+1 -1
View File
@@ -20,7 +20,7 @@
{{- end -}}
{{- partial "recently-updated.html" . -}}
{{- range $pages.PageGroups -}}
<h3 class="group-title">{{ .Key }}</h3>
<h3 class="group-title">{{ .Key }}</h3>
{{- range .Pages -}}
<article class="archive-item">
<a href="{{ .RelPermalink }}" class="archive-item-link">
+1
View File
@@ -221,6 +221,7 @@
{{- /* 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 -}}
{{- /* Custom script */ -}}
{{- if eq .Site.Params.customJS.enable true -}}
+3 -1
View File
@@ -53,7 +53,9 @@
{{- end -}}
{{- /* Total word count */ -}}
{{- if ne .Site.Params.footer.wordCount false -}}
{{- /* There is a fatal bug. See https://github.com/Lruihao/FixIt/issues/124 */ -}}
{{- /* if ne .Site.Params.footer.wordCount false */ -}}
{{- if false -}}
{{- $localData := newScratch -}}
{{- range (where .Site.Pages "Kind" "page") -}}
{{- $localData.Add "totalWordCount" .WordCount -}}