We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I want to write code snippets that are toggolable between JS and TS.
because, TS users wanna see implementation examples with Typings included but, JS users don't want to see this
Instead of having separate TS documentation, each code snippet should be toggolable between the two.
The change is to be implemented in the CodeBlock component: https://github.com/CyCraft/planetar/blob/production/packages/markdown/src/components/CodeBlock.vue
The syntax could be to accept an array of languages and content.
By default it will show: content[0] language[0], and then there is a toggle in the top right somewhere to switch to the second language and content.
content[0]
language[0]
currently the props look like this (need refactoring so they accept String | Array):
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I want to write code snippets that are toggolable between JS and TS.
because, TS users wanna see implementation examples with Typings included
but, JS users don't want to see this
Instead of having separate TS documentation, each code snippet should be toggolable between the two.
The change is to be implemented in the CodeBlock component:
https://github.com/CyCraft/planetar/blob/production/packages/markdown/src/components/CodeBlock.vue
The syntax could be to accept an array of languages and content.
By default it will show:
content[0]
language[0]
, and then there is a toggle in the top right somewhere to switch to the second language and content.currently the props look like this (need refactoring so they accept String | Array):
The text was updated successfully, but these errors were encountered: