Skip to content

Default to plaintext code instead of empty codeblock #13

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

Merged
merged 1 commit into from
Feb 16, 2021
Merged

Default to plaintext code instead of empty codeblock #13

merged 1 commit into from
Feb 16, 2021

Conversation

meghprkh
Copy link
Contributor

When autohighlighting and highlightjs is unable to detect the language

Fixes #12

When autohighlighting and highlightjs is unable to detect the language

Fixes #12
@wooorm
Copy link
Member

wooorm commented Feb 15, 2021

That definitely sounds like a bug!

Do you remember how to reproduce it? As it is a bug, it would be nice to have a test so it doesn’t happen again!

@meghprkh
Copy link
Contributor Author

This link shows the bug https://codesandbox.io/s/rehype-highlight-subset-bug-o1dnx?file=/src/index.js . Screenshot in #12

If you meant that it is a bug in highlightjs, I think that might be intended behaviour.

@wooorm wooorm merged commit 0e11f47 into rehypejs:main Feb 16, 2021
@wooorm
Copy link
Member

wooorm commented Feb 16, 2021

I can’t reproduce this locally, so it does seem like something changed in lowlight/highlight.js

@wooorm wooorm added ⛵️ status/released 🐛 type/bug This is a problem 👶 semver/patch This is a backwards-compatible fix 🗄 area/interface This affects the public interface labels Feb 16, 2021
@wooorm wooorm added the 💪 phase/solved Post is done label Aug 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🗄 area/interface This affects the public interface 💪 phase/solved Post is done 👶 semver/patch This is a backwards-compatible fix 🐛 type/bug This is a problem
Development

Successfully merging this pull request may close these issues.

Plain code when languages not in autodetect-subset, should stay unformatted but not become blank
2 participants