-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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(extension-code-block-lowlight): Bump lowlight to 2.7.0, remove outdated @types #3002
Conversation
✅ Deploy Preview for tiptap-embed ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
i also found that package-lock.json in /demos no longer gets used, i'm guessing from before lerna was used. it's probably worth just deleting that file, too. it made local testing very confusing. |
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 - will test this on the staging environment. Thanks for the PR! :)
It seems like code highlighting isn't working in the demo anymore. Could you check out what went wrong there? https://deploy-preview-3002--tiptap-embed.netlify.app/src/nodes/codeblocklowlight/react/ |
I think you now have to register the languages in the demos. Take a look here: Maybe that's why code highlighting currently isn't working. |
Any updates @tarngerine |
I’ll check it out today sorry for the delay! |
OK! I pushed fixes and checked the deploy preview, they all syntax highlight now. Thanks for the reference PR. |
Thank you a lot! :) |
Seems like the test is failing. Could you take a look into this again @tarngerine ? |
Closes #2880
Lowlight now has TS types in the package itself. This PR bumps to latest 2.7.0, and removes the @types package which is very out of date and actively prevents developers from using current version of lowlight (because @types always takes precedence over built in types, causing TS to throw errors, see #2880
We may also choose to leave lowlight at 1.2.0, but without @types built-in, it would add friction to devs who want to plug-and-play the CodeBlockLowlight extension. IMO updating to 2.7.0 preserves this single npm install experience.
FWIW the docs are a little confusing, the currently claim that:
which I would personally love, but the extension currently provides an out of date lowlight with types that prevent client apps from using the latest lowlight.
happy to also put up a version with that change (just removing lowlight from the extension)