Browser blocking lowlight library when using CodeBlockLowLight #2191
-
When I follow the example on the CodeBlockLowlight docs page I get a browser error. My code is: import { Editor, Mark } from 'https://cdn.skypack.dev/@tiptap/core?min';
import StarterKit from 'https://cdn.skypack.dev/@tiptap/starter-kit?min';
import CodeBlockLowLight from 'https://cdn.skypack.dev/@tiptap/extension-code-block-lowlight?min';
import lowlight from 'https://cdn.skypack.dev/lowlight@2?min'; When loading the page on Chrome I get this message for all 35 of the default lowlight languages:
On Firefox it also fails, but it's more verbose and mentions CORS issues:
Has anyone else experienced this issue? How might I go about debugging it? It's hard to believe all those files are missing from the CDN. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
I think codeBlockLowlight doesn’t officially support lowlight v2.x, so maybe it's about this? I’m not familiar with importing the libraries via a CDN, but see this issue for alternative ways to import the last version. |
Beta Was this translation helpful? Give feedback.
I think codeBlockLowlight doesn’t officially support lowlight v2.x, so maybe it's about this? I’m not familiar with importing the libraries via a CDN, but see this issue for alternative ways to import the last version.