Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple versions of documentation available at the same time #6

Open
SimplyLinn opened this issue Sep 8, 2022 · 4 comments
Open
Labels
documentation Improvements or additions to documentation enhancement New feature or request infrastructure Relating to the project's structure and CI/CD

Comments

@SimplyLinn
Copy link
Contributor

Having multiple docs live at once, for different versions, should be possible once this feature gets implemented in typedoc:
TypeStrong/typedoc#1180

And based on this commit, that seems to be in the working:
TypeStrong/typedoc@4008c89

But for now, showing the main branch should be sufficient.

@SimplyLinn SimplyLinn added documentation Improvements or additions to documentation enhancement New feature or request labels Sep 8, 2022
@jorins
Copy link
Contributor

jorins commented Dec 14, 2023

The mentioned issue has been resolved, though I'm not entirely sure what you had envisioned for this to solve.

An issue that discusses publishing multiple versions: TypeStrong/typedoc#737

I'd like to write a plugin to make switching between documentation versions easy. Just a drop down like the node docs. The structure I'm imagining for this is something like

  • / -> redirect to /latest
  • /dev <- published from dev branch
  • /next <- published from main branch
  • /latest <- published from latest tagged release, does not redirect but is identical to one tagged release
  • /vx.y.z <- published from tagged release x.y.z

Caching old results would be much preferable in the interest of keeping the pipeline from increasing in length with each release. I'm not entirely sure which caching mechanism would be the best here, would have to look into that.

@jorins
Copy link
Contributor

jorins commented Dec 15, 2023

Here's a plugin for typedoc 0.23 that does pretty much this: https://github.com/citkane/typedoc-plugin-versions

Unfortunately typedoc has had breaking API changes and it will not work with current versions of typedoc. Will need to investigate whether it's worth forking it or if it would be better to fully rewrite.

@jorins
Copy link
Contributor

jorins commented Dec 15, 2023

Another option is of course, to realise that we're currently on 0.23 and simply stay there. typedoc-plugin-extras, which I want to use for favicon, specifies 0.25 as its peer dependency, but even then its current release (3.0.0) seems to work on typedoc 0.23.

@jorins
Copy link
Contributor

jorins commented Dec 15, 2023

typedoc-plugin-versions expects you to maintain a branch for documentation. It's just a bit iffy to me. Something like the suggested method in the aforementioned issue may work but it's a five year old post and I dunno how relevant it is.

JSON output is available in 0.23 but JSON input wasn't possible until 0.24. All in all I think we should absolutely upgrade and build a solution without typedoc-plugin-versions.

@jorins jorins added the infrastructure Relating to the project's structure and CI/CD label Dec 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request infrastructure Relating to the project's structure and CI/CD
Projects
None yet
Development

No branches or pull requests

2 participants