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

Allow for Syntect to simply generate CSS classes #347

Merged
merged 3 commits into from
Nov 29, 2023
Merged

Conversation

gjtorikian
Copy link
Collaborator

Syntect has the ability to generate its syntax highlighting with CSS classes, rather than inline styles.

I wanted to use this in Commonmarker, but I couldn't find an easy, non-breaking API to support this feature. I'm happy to rework or rearchitect it into anything that looks better. Technically this is still a non-1.0 library so breaking changes are permitted per sem ver, but, well, you know.... people.

Copy link
Contributor

Command Mean [ms] Min [ms] Max [ms] Relative
./bench.sh ./comrak-aaa95b7 401.4 ± 2.8 397.4 408.2 3.25 ± 0.06
./bench.sh ./comrak-main 407.0 ± 2.0 403.4 411.3 3.29 ± 0.06
./bench.sh ./pulldown-cmark 123.7 ± 2.2 121.4 131.8 1.00
./bench.sh ./cmark-gfm 146.6 ± 2.5 144.2 154.8 1.19 ± 0.03
./bench.sh ./markdown-it 609.9 ± 3.6 603.4 616.0 4.93 ± 0.09

Run on Sun Nov 12 03:18:37 UTC 2023

@gjtorikian gjtorikian force-pushed the use-css-if-you-like branch 2 times, most recently from 2295792 to b33e337 Compare November 12, 2023 15:50
@kivikakk kivikakk force-pushed the use-css-if-you-like branch from b33e337 to 4b9d838 Compare November 29, 2023 04:36
@kivikakk
Copy link
Owner

Thank you so much! ❤️

@kivikakk kivikakk enabled auto-merge November 29, 2023 04:37
@kivikakk kivikakk merged commit 769b4e5 into main Nov 29, 2023
24 checks passed
@kivikakk kivikakk deleted the use-css-if-you-like branch November 29, 2023 04:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants