-
Notifications
You must be signed in to change notification settings - Fork 281
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
Use highlight.js to add syntax highlighting to the generated HTML documents. #68
Conversation
If there are any issues that cannot be merged, please point them out so I can make revisions. |
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.
ok
@jetmit The code is fine, but there are two issues:
|
The border of the code snippet was originally a 1em padding in the code block, which I found too wide and changed to 0.375; because the color differs from the highlight color, it appears as a border. I also prefer a minimalist and elegant design; however, when the documentation is sent to front-end developers, they feel it's somewhat plain. Therefore, I wanted to add code highlighting, which also makes the structure clearer. We can continue to adjust and optimize going forward, enhancing the code block section for better completeness. |
@jetmit The code is fine, but there are two issues:
The original code block background was F7F7F8, and the added default GitHub theme background is F8F8F8, which looks identical to the naked eye. The white background with borders shown in the screenshot above is a random other style, not the default. -- |
Use highlight.js to add syntax highlighting to the generated HTML documents.
Users can configure the
style
option in thesmart-doc
configuration file (optional).Style values:
Effect:
