Skip to content
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

New Utility: CodeBlock #52

Closed
endigo9740 opened this issue Aug 4, 2022 · 5 comments · Fixed by #55
Closed

New Utility: CodeBlock #52

endigo9740 opened this issue Aug 4, 2022 · 5 comments · Fixed by #55
Assignees
Labels
complete The issue has passed QA and is ready to merge documentation Improvements or additions to documentation enhancement New feature or request ready to test Ready to be tested for quality assurance.

Comments

@endigo9740
Copy link
Contributor

The Skeleton documentation has been using the <CodeBlock> component internally for a white. I believe it's adequately mature now. Let's go ahead and document this and make available as part of the library.

This will include the following changes:

  • Add Utilities > Code Blocks to the Skeleton docs navigation
  • Minor updates to the CodeBlock documentation, including instructions for setting up Highlight.js
  • Add the CodeBlock component to the package exports in /lib/index.js
@endigo9740 endigo9740 self-assigned this Aug 4, 2022
@endigo9740 endigo9740 added documentation Improvements or additions to documentation enhancement New feature or request labels Aug 4, 2022
@endigo9740
Copy link
Contributor Author

@thomasbjespersen This is now ready for QA. Thanks!

@endigo9740 endigo9740 added the ready to test Ready to be tested for quality assurance. label Aug 4, 2022
@thomasbjespersen
Copy link
Contributor

thomasbjespersen commented Aug 5, 2022

@endigo9740 Any reason why you are not specifying HTML as lang in the usage section, and instead using plaintext?

<CodeBlock code={'...'}></CodeBlock>

@endigo9740
Copy link
Contributor Author

endigo9740 commented Aug 5, 2022

@thomasbjespersen I see what you mean, Highlight.js wasn't properly highlighting the inner CodeBlock snippet because of the Svelte syntax. They support a ton of languages but unfortunately Svelte is not yet one of them.

https://highlightjs.org/static/demo/

@thomasbjespersen
Copy link
Contributor

thomasbjespersen commented Aug 5, 2022

@endigo9740 I think I get what you are saying.. Lets leave this as is..

@thomasbjespersen
Copy link
Contributor

We are good to merge this branch to master, @endigo9740.

@thomasbjespersen thomasbjespersen added the complete The issue has passed QA and is ready to merge label Aug 6, 2022
@endigo9740 endigo9740 linked a pull request Aug 6, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
complete The issue has passed QA and is ready to merge documentation Improvements or additions to documentation enhancement New feature or request ready to test Ready to be tested for quality assurance.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants