documentation - add javascript examples to docs and tutorials. #2234
karl-cardenas-coding
started this conversation in
Proposals
Replies: 1 comment
-
I wonder if adding something like this to the docs will allow them to dynamically remove the TypeScript types from the examples. https://github.com/cyco130/detype |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
At the moment, most of the example code snippets are in TypeScript, but there are others that are in Javascript. Ideally, it would be nice to have a tab for the user to toggle between the language of choice. I've added an example screenshot of what HashiCorp does with their docs. In the example, the user can toggle between HCL or JSON. Source
This way, you can keep the existing code snippets but not be opinionated when informing the end-user. This would also help improve the documentation experience as the inconsistency between the usage of the two languages could be removed.
Beta Was this translation helpful? Give feedback.
All reactions