-
Notifications
You must be signed in to change notification settings - Fork 89
feat: Add shortcode for the latest version of NGINX Gateway Fabric #203
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
Conversation
This commit adds a new shortcode to the layouts folder to store a string representing the latest version of NGINX Gateway Fabric. This means that instead of updating each file individually during a new release, only the shortcode file needs to be modified. It clarifies the versioning for documentation, which makes it easier to review - and also reduces the amount of drift when updating, in the case that a reference was overlooked. There may be old references that need to be updated to use this shortcode.
✅ Deploy Preview will be available once build job completes!
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check for any 1.5.1 instances as well, I think those were seen in an includes for the install docs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Question: while I like this idea, I think this looks like "nesting includes," which our style guide suggests we avoid. @travisamartin WDYT?
Ooh, I forgot about this. I think it was largely to avoid situations where skeletons of pages would be built in refraction: this is nested re-used content, but the scope is probably the tightest you could get for an include. Subsequent to affected pages are watching the version string increment as opposed to reviewing 16 separate files. |
As I think I implied, I'd welcome this kind of exception to the style guide. |
I don't consider a variable shortcode inside an include a nested include, as the real content of the variable can be "guessed" or at least understood without having to open the source file with the actual value. The issue with nested variables is obfuscating the real content to the point that it's not possible to effectively review the document |
To clarify, I've opened #207 |
Proposed changes
This commit adds a new shortcode to the layouts folder to store a string representing the latest version of NGINX Gateway Fabric. This means that instead of updating each file individually during a new release, only the shortcode file needs to be modified.
It clarifies the versioning for documentation, which makes it easier to review - and also reduces the amount of drift when updating, in the case that a reference was overlooked. There may be old references that need to be updated to use this shortcode.
Closes #199
Checklist
Before merging a pull request, run through this checklist and mark each as complete.
README.md
andCHANGELOG.md
Potentially sensitive changes include anything involving code, personally identify information (PII), live URLs or significant amounts of new or revised documentation.
Please refer to our style guide for guidance about placeholder content.