-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
[Docs] Add minimal nuxt version to feature/utility - may be a label or a badge #24950
Comments
A great idea - and @Atinux and I have talked about this... If we can't automate it, then it would be nice to annotate. |
I remember this was a topic a few times ago and I'm also all for it. Helpful for upgrading versions or when new (future) features are committed but not released yet 👍🏻 |
@Atinux not sure if that fully closes the issue as documenting the "first version available" of most features would be nice. |
callOnce was just an example of how important it is to provide minimal version info across every feature. I understand that it would be impossible to keep versioning whole docs to each nuxt version for various reasons, so this is why a small notice would be helpful. Small projects can often be up-to-date, but when we talk about large-scale apps with a lot of dependencies it is not so obvious that they can be updated on day 1. |
Sure thing! Happy to re-open it as we can improve the docs along the way for each composable / feature with the minimal version associated to it 👍 |
Linking #23189 |
Hello, this is a great idea! I remember when developing with WordPress they used It would be easy enough to add @since JSDoc annotations moving forward. It would be time consuming but not too difficult to look back through the changelogs of releases to see when new functions were added. The docs build would need updating to read and reference the versions. |
@luc122c An |
@manniL I've just had a play and although the JSDoc does not show in the IDE, the annotation does carry across to the definition file. Perhaps this is something that could be picked up by an extension (e.g. Volar or Nuxtr)? |
I've started adding I've also had a look at how the documentation works, but I'm not sure where we can hook in to read this info and inject it into the docs? I see there are hooks available in unbuild but I'm not sure what they are, or if that's even the right place? |
Roadmap for completing this issue:
Please let me know if there are any additional requests/ideas (e.g. annotating components) |
Describe the feature
Nuxt 3.9 introduced new utility called callOnce. https://nuxt.com/docs/api/utils/call-once
However, if you are reading that page you have no idea that Nuxt 3.9 is required in order to use that utility. Maybe it would be possible to mark minimal nuxt version for a feature to work? It can be implemented as a badge or label.
This information can be:
minimalVersion
inside frontmatterI believe that simple
:badge[v3.9]
from Docus is more than enoughAdditional information
Final checks
The text was updated successfully, but these errors were encountered: