-
-
Notifications
You must be signed in to change notification settings - Fork 6.4k
fix: use rehype-shikiji #6054
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
fix: use rehype-shikiji #6054
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Hey @ovflowd, |
Right, it is expected. Sorta. We can always make a css fix on a follow up PRs. The empty lines are still there, but just have no styling. I have the feeling thats what rehype-pretty-code was doing + a bunch of other things like the line numbers. So either we abandon rehype-pretty-code and implement these things by ourselves or eventually we move back to that library once they moved to shikiji |
Also @canerakdas feel free to tackle the style empty line issue if you want :) (at least as a hot fix on the legacy css) |
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.
LGTM!
Also @devjvao as this might be interesting for your Codebox PR, i.e., line numbers and empty line spacing/padding |
Description
This PR temporarily moves from
rehype-pretty-code
torehype-shikiji
, since right now,rehype-pretty-code
would needshikiji-compat
to work withrehype-pretty-code,
and unfortunately, that uses Node.js specific APIs.The functionality of rehype-shikiji is slightly different; hence let's keep an 👀 once
rehype-pretty-code
moves toshikiji
.Validation
All syntax highlighting should still work. Keep in mind empty lines will have a different effect for the meantime.