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

feat: Add alias condition to code-block-lowlight #3155

Merged
merged 1 commit into from
Sep 14, 2022

Conversation

dngwoodo
Copy link
Contributor

@dngwoodo dngwoodo commented Sep 6, 2022

Lowlight's lowlight.listLanguages does not support alias.

So, for example, if you use alias called js, it is not parsed properly.

Currently, a method called registered exists in the lowlight 2 version, but it does not exist in the 1 version, so this part is directly implemented.

Please check and merge.

@netlify
Copy link

netlify bot commented Sep 6, 2022

Deploy Preview for tiptap-embed ready!

Name Link
🔨 Latest commit 58f2e03
🔍 Latest deploy log https://app.netlify.com/sites/tiptap-embed/deploys/6316eb86fd4e4c00082eb88c
😎 Deploy Preview https://deploy-preview-3155--tiptap-embed.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@bdbch
Copy link
Contributor

bdbch commented Sep 10, 2022

We just upgraded lowlight in our demos to 2.7.0

Do you think this PR is still needed @dngwoodo

@dngwoodo
Copy link
Contributor Author

dngwoodo commented Sep 10, 2022

The code const nodes = language &&'(language.includes(language) || registered(language)) is still needed. Even if you upgrade lowlight, alias is still not checked.

And I think there might be a user who uses a lowlight low version.

@bdbch

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