Node: docs: Version switcher is broken / misleading

Created on 30 Oct 2018  路  8Comments  路  Source: nodejs/node

Currently if you try to switch to other semver major versions of the same docs on the docs site, you get extremely inconsistent results. Questions I had as I was going throught

As an example, here are the HTTP/2 docs:

v8.x
image

v9.x (where is v8.x?)
image

v10.x (where is v8.x, and why wasn't this doc listed on the v8.x or v9.x docs pages?)
image

v11.x (why wasn't this listed on any of the other pages?)
image

I experienced this in a few other docs pages as well.

doc

Most helpful comment

So AFAICT it depends on what was backported when...
I think since v8.0.0 did not have HTTP/2 our inference logic fails.
Also we have the limitation that once a doc version was built it is static. ATM we don't have a way to update it of newer versions.

All 8 comments

I鈥檓 not sure who to ping for this, but I鈥檓 sure @rubys or @vsemozhetbyt would know?

Not sure of the answer to all of the questions, but at least for:

v11.x (why wasn't this listed on any of the other pages?)

I think we need to add to:
https://github.com/nodejs/node/blob/2cab511d956145579049a5183b5c05fd50fee412/tools/doc/html.js#L403-L416
and get it backported to all non-EOL release lines. I'll raise a PR (edit: https://github.com/nodejs/node/pull/23980).

So AFAICT it depends on what was backported when...
I think since v8.0.0 did not have HTTP/2 our inference logic fails.
Also we have the limitation that once a doc version was built it is static. ATM we don't have a way to update it of newer versions.

If we want this to work for backported docs, maybe we need to move this from doctools to some webpage dynamic script.

It is possible, but i am not sure it is worth all the hard work for that small feature.
Maybe just fix it manually in the backported docs?

The cause here is a bug in tools/doc/html.js. PR coming shortly.

Fix landed in 6f64cda. Not sure why this didn't auto-close....

Was this page helpful?
0 / 5 - 0 ratings

Related issues

willnwhite picture willnwhite  路  3Comments

jmichae3 picture jmichae3  路  3Comments

sandeepks1 picture sandeepks1  路  3Comments

addaleax picture addaleax  路  3Comments

vsemozhetbyt picture vsemozhetbyt  路  3Comments