@zubyjs/preact 1.0.69 → 1.0.71

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.
Files changed (2) hide show
  1. package/package.json +5 -5
  2. package/render.js +2 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zubyjs/preact",
3
- "version": "1.0.69",
3
+ "version": "1.0.71",
4
4
  "description": "Zuby.js JsxProvider for Preact",
5
5
  "type": "module",
6
6
  "main": "index.js",
@@ -16,10 +16,10 @@
16
16
  "linkDirectory": true
17
17
  },
18
18
  "dependencies": {
19
- "@preact/preset-vite": "^2.8.1",
20
- "wouter-preact": "^2.12.2",
21
- "preact-render-to-string": "^6.3.1",
22
- "preact": "^10.19.3"
19
+ "@preact/preset-vite": "2.8.1",
20
+ "wouter-preact": "2.12.2",
21
+ "preact-render-to-string": "6.4.0",
22
+ "preact": "10.19.6"
23
23
  },
24
24
  "peerDependencies": {
25
25
  "zuby": "^1.0.0"
package/render.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { h, options, cloneElement } from 'preact';
2
- import { render as preactRenderToString } from 'preact-render-to-string';
2
+ import { renderToStringAsync as preactRenderToStringAsync } from 'preact-render-to-string';
3
3
  import { Readable } from 'stream';
4
4
  let vnodeHook;
5
5
  const old = options.vnode;
@@ -33,8 +33,7 @@ export const renderToString = async (vnode, options) => {
33
33
  return '';
34
34
  }
35
35
  try {
36
- // @ts-ignore
37
- return preactRenderToString(vnode);
36
+ return preactRenderToStringAsync(vnode);
38
37
  }
39
38
  catch (e) {
40
39
  if (e instanceof Promise) {