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

fix: dont inject styles without code #162

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

codepunkt
Copy link
Contributor

Fixes #161

Is this also a problem with Gatsby?

@@ -155,7 +155,11 @@ function remarkPlugin(options = {}) {
// time, change the original code fence Markdown node to an HTML node and set
// its value to the HTML rendering contained in the GraphQL node.

let numCodeOccurrences = 0;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be nicer to just be able to ask codeNodeRegistry.isEmpty() or something

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.

When used without gatsby, injects styles when neither code spans nor code blocks have been found
2 participants