clickhouse-docs
clickhouse-docs copied to clipboard
Version individual sections for clients
As discussed https://github.com/ClickHouse/clickhouse-docs/pull/3071 it would be nice if we could have a single page with multiple versions, so that docs could be collapsed - it would help customers find the current version, while still allowing older access.
@gingerwizard Is this something you're aware of how to do?
yes we'll handle @Paultagoras
https://github.com/facebook/docusaurus/issues/2528 ideal i think
Adopting the Docusaurus approach to versioning on this isn't going to work without substantial changes to the structure of the docs I don't think - it's designed more for the use case where your entire project has a single version, rather than having different pages versioned.
@Paultagoras what if we have a React component which is a dropdown menu item on the page itself somewhere near the top of the page that can be used to select the version? When the user selects the version it will just do a page change. We use this trick here https://clickhouse.com/docs/knowledgebase for the component that lets you switch between "Recent" and "Grouped by tags". It's actually two separate pages but it gives the illusion that it's a single page application.
Like this but on the page itself rather than in a menu:
Only downside I can really think of is that we'll need to import this component on every version markdown page and have to manually update it on each page every time a new version is added. If new versions are infrequent then this shouldn't be too much of a problem either.