svelte-prism-action 1.1.0 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -83,6 +83,10 @@ You can also change the IntersectionObserver options. For more information on wh
83
83
 
84
84
  ## Changelog
85
85
 
86
+ ### 1.1.1 (2023-03-15)
87
+
88
+ - Fix: SvelteKit error while loading prism-markup.js
89
+
86
90
  ### 1.1.0 (2023-03-15)
87
91
 
88
92
  - Add: support for third party language files
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "svelte-prism-action",
3
- "version": "1.1.0",
3
+ "version": "1.1.1",
4
4
  "description": "Svelte action for lazy render code blocks with prism.js.",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -6,7 +6,6 @@ if (typeof window !== "undefined") {
6
6
 
7
7
  import { tick } from "svelte";
8
8
  import Prism from "prismjs/components/prism-core";
9
- import "prismjs/components/prism-markup";
10
9
  import getLoader from "prismjs/dependencies";
11
10
  import { components } from "./components";
12
11
 
@@ -137,6 +136,9 @@ export function prism(node, params) {
137
136
  });
138
137
  }
139
138
 
139
+ //load markup component, is needed for all languages
140
+ import(/* @vite-ignore */ "prismjs/components/prism-markup");
141
+
140
142
  //wait for onMount on parent
141
143
  let observer;
142
144