We use analytics and cookies to understand site traffic. Information about your use of our site is shared with Google for that purpose. Learn more.
Shortcodes: Website widgets
A list and examples of the custom shortcodes that are currently used and available in knative.dev.
STAUS: This page is in “draft state” and needs to be completed.
Knative custom shortcodes
https://github.com/knative/website/tree/main/layouts/shortcodes
All of these Knative shortcodes are added as examples in the smoketest pages
Learn more about shortcodes
-
Hugo shortcodes https://github.com/gohugoio/hugo/tree/master/docs/layouts/shortcodes
- How to create custom shortcodes https://gohugo.io/templates/shortcode-templates/
-
Docsy shortcodes https://www.docsy.dev/docs/adding-content/shortcodes/
-
Other shortcodes https://github.com/spf13/spf13.com/tree/master/layouts/shortcodes
Includes
Include files and code samples with the readfile
shortcode:
https://github.com/knative/website/blob/main/layouts/shortcodes/readfile.md
Dynamic variables
Use them to reduce release maintenance and ensure content accuracy.
The following variable are dynamically populated based on the URL of the content in knative.dev:
- The branch shortcode
{
renders:{< branch >}
}release-0.22
- The version shortcode
{
renders:{< version >}
}v0.22.0
Artifacts
https://github.com/knative/website/pull/129/files
Tabs
https://github.com/knative/website/pull/124
Feedback
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.