openzim / devdocs

devdocs.io to ZIM scraper
GNU General Public License v3.0
2 stars 0 forks source link

Dynamically render the navigation bar #24

Closed josephlewis42 closed 2 weeks ago

josephlewis42 commented 1 month ago

Currently, the navigation bar is generated for each document using a template. This leads to the following issues:

Instead, we should dynamically generate the navbar using JS and some kind of optimized navigation intermediate representation in JSON that encodes all the special sorting and special case links that DevDocs does.

benoit74 commented 1 month ago

Agreed, thank you for detailing the issue and plan!

josephlewis42 commented 1 month ago

I'm working on this now. It's my first time using Vue2, WebComponents, and TypeScript together so there are a lot of learning opportunities!

benoit74 commented 1 month ago

I hope you misspelled Vue2 and meant Vue3 ^^

If you did not already found it, you might be interested to have a look into https://github.com/openzim/youtube/tree/main/zimui or the soon-to-be-merged https://github.com/openzim/libretexts/tree/minimal_structure/zimui

Not that we are Vue3 experts at all, but this is our "state of the art" with our limited experience so far.