Open
Description
Is your feature request related to a problem? Please describe.
After addressing the problem of memory overflow (issue #3362, pr #3366), I ended up producing a bundle that, although worked fine, turned out to be very large in size. Especially when compared to the original content size.
I investigated the produced html source tree and found each of them contains a copy of their corresponding navbar and sidebar, parsed into html template.
Describe the solution you'd like
Instead of hard-coding the sidebar (and maybe the navbar) as html templates into each entry file, provide a configuration switch to fall back to client side rendering with their data chunked separately as JSON files.
Describe alternatives you've considered
Not applicable
Additional context
To provide an idea of the scale of size, here is a summary of related objects in my project:
File | Size | Description |
---|---|---|
nav.json | 10KB | Serialized nav object |
sidebar.json | 414KB | Serialized sidebar object |
cache/ | 25MB | Cached raw html files before conversion to vitepress |
dist/ | 1.7GB | Bundle produced by vitepress |
And here is a link of the deployed site: x.z-yx.cc
Validations
- Follow our Code of Conduct
- Read the docs.
- Read the Contributing Guidelines.
- Check that there isn't already an issue that asks for the same feature to avoid creating a duplicate.