Skip to content

Commit

Permalink
fix: ebook script
Browse files Browse the repository at this point in the history
  • Loading branch information
novalagung authored Feb 8, 2024
1 parent 5372492 commit e260d0b
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions etc/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -147,8 +147,14 @@ func webbookPostAdjustment() {
htmlString = strings.ReplaceAll(htmlString, imagesAltToFind, imagesAltReplacement)

// ==== disqus lazy load
disqusJSBuf, _ := os.ReadFile("./gitbook-plugin-disqus.js")
os.WriteFile("./_book/gitbook/gitbook-plugin-disqus/plugin.js", disqusJSBuf, 0644)
disqusJSBuf, err := os.ReadFile("./gitbook-plugin-disqus.js")
if err != nil {
fmt.Println("error", err)
}
err = os.WriteFile("./_book/gitbook/gitbook-plugin-disqus/plugin.js", disqusJSBuf, 0644)
if err != nil {
fmt.Println("error", err)
}

// ==== gitbook assets lazy load
cssToLoad := []string{
Expand Down

0 comments on commit e260d0b

Please sign in to comment.