-
Notifications
You must be signed in to change notification settings - Fork 71
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
Make documentation for old versions available #178
Comments
Hey @hiredgunhouse thanks for the issue. I agree with this. It would indeed be great. Right now the docs are generated from the source code, you can see in the https://github.com/chaijs/chaijs.github.io/ repo there is a Makefile which has an It would take some work but I think it is do-able to have the Makefile generate multiple datasets from different versions, then re-architect the site docs to point to a specific version. If you have the time to make a PR I'd love to see what you come up with, and I'm also happy to help where I can. |
Maybe it would be nice to show for each api assertion, from which minimum version it is available in chai. Just my two cents, if this might be easier to implement. |
Supporting a "version introduced at" piece of meta is also possible - but we could add this as an annotation to the doc blocks in the code comments. It'd be less difficult to implement overall but would probably be more work going through every method in the codebase and figuring out when it was available. There's one subtle problem with just documenting when a method was introduced: often methods are removed, or change - this is more complex than just availability. For example some assertions only used to accept numbers but now accept dates as well - how can this be articulated? |
Hey @keithamus, sounds good, I'll give this a shot and try to make a PR. |
@hiredgunhouse thanks for picking this up! Let me know if you need any assistance with this. I'll try my best to offer advice where I can 😄 |
@keithamus a quick update: I'm slowly working through this, please be patient. |
Thanks @hiredgunhouse for looking into this! Workaround (for future people trying to find older API docs):The API docs are being generated from comments in the source code. It's not pretty, but if you search through this file, you might find what you were looking for: https://github.com/chaijs/chai/blob/3.5.0/lib/chai/core/assertions.jsSelect your release version through the github "tags" |
For a library like Chai I think it is very important to have the docs for old versions available online.
Having docs for the latest version only is problematic for people who are on projects using some older version because new APIs are not available to us and we can only learn that by trial and error.
The text was updated successfully, but these errors were encountered: