Post

An issue with Chirpy theme on TOC

This guide is specifically for Windows 10 users.

Alt Text Figure 1. Nothing shows under the contents.

After executing bundle exec jekyll serve on ruby prompt, I encountered some issues: the Table of Contents(TOC) didn’t show up, as showin in Figure 1, and the website behaved abnormally on mobile phone environments. Users in the forum suggested various solutions, but none of them directly resolved my issue.

The problem stemmed from certain JavaScript files not being generated in my directory, and the commands provided in the forum post didn’t work on Windows 10:

1
2
npm install
NODE_ENV=production npx rollup -c --bundleConfigAsCjs

And ChatGPT resolved the issue. For Windows 10 users, you can run the following script:

1
set NODE_ENV=production && npx rollup -c --bundleConfigAsCjs

To be frank, I had executed numerous scripts beforhand. Therefore, I am not sure some other commands should be executed in advance (Probably, npm should be downloaded from https://nodejs.org/en/download). I hope this information helps others who may be facing similar challenges.

reference

This post is licensed under CC BY 4.0 by the author.

Comments powered by Disqus.