svelte-highlight
svelte-highlight copied to clipboard
Syntax Highlighting for Svelte using highlight.js
Closes #215 This is technically a breaking change so the major version should be incremented. This changes the semantics of how `code` and `language` props are typed. Both should be...
Currently, code styles are applied globally. It could be useful if styles code be scoped, which would allow the ability use different styles in the same page. The docs site...
Currently, the `code` and `language` props are marked as optional because they have default values. They should be typed as required props since the component wouldn't work without them. -...
This repository adds support for the Solidity language in Highlight.js: https://github.com/highlightjs/highlightjs-solidity Would be great to have natively on svelte-highlight!
# No HTML language available highlight.js has HTML as one of its supported language but for some reason svelte-highlight doesn't have an import available for the language. ## Reproductible demo...
code: ``` import { Highlight } from "svelte-highlight"; import json from "svelte-highlight/src/languages/json"; import github from "svelte-highlight/src/styles/github"; {@html github} ``` get error: ``` core.js?v=c35c3444:2 Uncaught (in promise) SyntaxError: The requested module...
Is it possible to pass code using a slot instead of a prop? For example, I'd like to be able to do ` const a = "test"; ` instead of...
So I need to highlight some date retuned from a remote endpoint using fetch. Could you show and example for hi-lighting the JSON returned in this REPL example: https://svelte.dev/repl/a74f1ed8e3eb4aec82cb743e13443ee4?version=3.48.0
We use the Highlight component in our website which is deployed on Vercel. The syntax highlighting will work locally, but will not work once deployed to Vercel. The line numbers...
Basically, allow us to change things like roundness, width, etc. Currently I am doing so by doing: ```svelte :global(pre) { // styles } ```