@ethercorps/sveltekit-og 1.1.1 → 1.2.3

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
@@ -3,6 +3,23 @@
3
3
  About
4
4
  Generate Open Graph Images dynamically from HTML/CSS without a browser in SvelteKit.
5
5
 
6
+ ## v1.2.3 Update (Breaking Changes)
7
+ > Now you have to install dependency by yourself which will make it easier to build for all plateforms.
8
+
9
+ ```
10
+ pnpm i @resvg/resvg-js
11
+ ```
12
+
13
+ ```
14
+ pnpm i satori
15
+ ```
16
+
17
+ > From now on their will be no issues related to build, and soon this library going to have its own documentation.
18
+
19
+ ## v1.2.2 Update (Breaking Change)
20
+
21
+ - We don't provide access to satori from `@ethercorps/sveltekit-og`.
22
+
6
23
  ## v1.0.0 Update (Breaking Changes)
7
24
 
8
25
  Finally, We have added html to react like element like object converter out of the box and with svelte compiler.
package/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import satori, { type SatoriOptions } from 'satori';
1
+ import { type SatoriOptions } from 'satori';
2
2
  import type { SvelteComponent } from 'svelte';
3
3
  import toReactElement from './toReactElement';
4
4
  declare const ImageResponse: (htmlTemplate: string, optionsByUser: ImageResponseOptions) => Promise<Response>;
@@ -13,4 +13,4 @@ type ImageOptions = {
13
13
  loadAdditionalAsset?: (languageCode: string, segment: string) => Promise<SatoriOptions['fonts'] | string | undefined>;
14
14
  };
15
15
  type ImageResponseType = typeof ImageResponse;
16
- export { componentToImageResponse, ImageResponse, toReactElement, satori, type ImageResponseType };
16
+ export { componentToImageResponse, ImageResponse, toReactElement, type ImageResponseType };
package/index.js CHANGED
@@ -48,4 +48,4 @@ const componentToMarkup = (component, props = {}) => {
48
48
  }
49
49
  return htmlTemplate;
50
50
  };
51
- export { componentToImageResponse, ImageResponse, toReactElement, satori };
51
+ export { componentToImageResponse, ImageResponse, toReactElement };
package/package.json CHANGED
@@ -1,39 +1,37 @@
1
1
  {
2
2
  "name": "@ethercorps/sveltekit-og",
3
- "version": "1.1.1",
3
+ "version": "1.2.3",
4
4
  "private": false,
5
5
  "devDependencies": {
6
- "@playwright/test": "^1.28.1",
6
+ "@playwright/test": "^1.34.3",
7
7
  "@sveltejs/adapter-auto": "next",
8
- "@sveltejs/kit": "1.0.0-next.581",
8
+ "@sveltejs/adapter-vercel": "^2.4.3",
9
+ "@sveltejs/kit": "1.10.0",
9
10
  "@sveltejs/package": "next",
10
- "@typescript-eslint/eslint-plugin": "^5.46.0",
11
- "@typescript-eslint/parser": "^5.46.0",
12
- "autoprefixer": "^10.4.13",
11
+ "@typescript-eslint/eslint-plugin": "^5.59.9",
12
+ "@typescript-eslint/parser": "^5.59.9",
13
+ "autoprefixer": "^10.4.14",
13
14
  "brace": "^0.11.1",
14
- "eslint": "^8.29.0",
15
- "eslint-config-prettier": "^8.5.0",
15
+ "eslint": "^8.42.0",
16
+ "eslint-config-prettier": "^8.8.0",
16
17
  "eslint-plugin-svelte3": "^4.0.0",
17
- "monaco-editor": "^0.34.1",
18
- "postcss": "^8.4.19",
19
- "prettier": "^2.8.1",
20
- "prettier-plugin-svelte": "^2.9.0",
18
+ "postcss": "^8.4.24",
19
+ "prettier": "^2.8.8",
20
+ "prettier-plugin-svelte": "^2.10.1",
21
21
  "prismjs": "^1.29.0",
22
- "svelte": "^3.54.0",
23
- "svelte-check": "^2.10.2",
22
+ "svelte": "^3.59.1",
23
+ "svelte-check": "^2.10.3",
24
24
  "svelte-preprocess": "^4.10.7",
25
- "tailwindcss": "^3.2.4",
26
- "tslib": "^2.4.1",
27
- "typescript": "^4.9.4",
28
- "vite": "^4.0.0"
25
+ "tailwindcss": "^3.3.2",
26
+ "tslib": "^2.5.3",
27
+ "typescript": "^4.9.5",
28
+ "vite": "^4.3.9"
29
29
  },
30
30
  "type": "module",
31
31
  "dependencies": {
32
- "@resvg/resvg-js": "^2.2.0",
33
- "satori": "^0.0.44"
34
- },
35
- "peerDependencies": {
36
- "svelte": "^3.54.0"
32
+ "@resvg/resvg-js": "^2.4.1",
33
+ "satori": "^0.10.1",
34
+ "svelte": "^3.59.1"
37
35
  },
38
36
  "keywords": [
39
37
  "open graph image",
@@ -6,5 +6,5 @@ interface VNode {
6
6
  [prop: string]: any;
7
7
  };
8
8
  }
9
- declare const toReactElement: (htmlString: string) => VNode;
9
+ export declare const toReactElement: (htmlString: string) => VNode;
10
10
  export default toReactElement;
package/toReactElement.js CHANGED
@@ -50,7 +50,7 @@ const root = {
50
50
  }
51
51
  };
52
52
  /* End of satori-html */
53
- const toReactElement = (htmlString) => {
53
+ export const toReactElement = (htmlString) => {
54
54
  const svelteAST = parse(htmlString);
55
55
  walk(svelteAST, {
56
56
  enter(node, parent, prop, index) {