This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
[✨] Add extra syntax highlighters via. MDX config #86
Labels
[STAGE-2] incomplete implementation
Remove this label when implementation is complete
[STAGE-2] not fully covered by tests yet
Remove this label when tests are verified to cover the implementation
[STAGE-2] unresolved discussions left
Remove this label when all critical discussions are resolved on the issue
[STAGE-3] docs changes not added yet
Remove this label when the necessary documentation for the feature / change is added
[STAGE-3] missing 2 reviews for RFC PRs
Remove this label when at least 2 core team members reviewed and approved the RFC implementation
Is your feature request related to a problem?
Currently, I cannot seem to register extra languages to refractor as it is run as part of the Vite build process via. a plugin.
As you can see, this does register the tsx syntax but nothing else - https://github.com/BuilderIO/qwik/blob/6f3f0ef5a8eb472a9dab0e934a5327dd1005cfb2/packages/qwik-city/buildtime/markdown/syntax-highlight.ts
Describe the solution you'd like
Allow specifying additional languages to be registered.
This might be best done via. a 'setup' callback, which has access to the
Refractor
object:This
setup
callback would be passed to therehypeSyntaxHighlight
plugin and called there.Describe alternatives you've considered
I tried to import
refractor
and register new languages in theroot.tsx
as part of auseTask$
but it had no effect.Additional context
No response
The text was updated successfully, but these errors were encountered: