piral-solid 0.15.9-beta.5420 → 0.15.9-beta.5435
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 +2 -2
- package/esm/converter.js +1 -1
- package/lib/converter.js +3 -3
- package/package.json +5 -5
- package/src/converter.ts +1 -1
package/README.md
CHANGED
|
@@ -75,14 +75,14 @@ const instance = createInstance({
|
|
|
75
75
|
});
|
|
76
76
|
```
|
|
77
77
|
|
|
78
|
-
The `solid-js` and `solid-js/
|
|
78
|
+
The `solid-js` and `solid-js/web` packages should be shared with the pilets via the *package.json*:
|
|
79
79
|
|
|
80
80
|
```json
|
|
81
81
|
{
|
|
82
82
|
"importmap": {
|
|
83
83
|
"imports": {
|
|
84
84
|
"solid-js": "",
|
|
85
|
-
"solid-js/
|
|
85
|
+
"solid-js/web": ""
|
|
86
86
|
}
|
|
87
87
|
}
|
|
88
88
|
}
|
package/esm/converter.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { onCleanup } from 'solid-js';
|
|
2
|
-
import { render, createComponent } from 'solid-js/
|
|
2
|
+
import { render, createComponent } from 'solid-js/web';
|
|
3
3
|
import { createExtension } from './extension';
|
|
4
4
|
export function createConverter(config = {}) {
|
|
5
5
|
const { rootName = 'piral-slot' } = config;
|
package/lib/converter.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.createConverter = void 0;
|
|
4
4
|
const solid_js_1 = require("solid-js");
|
|
5
|
-
const
|
|
5
|
+
const web_1 = require("solid-js/web");
|
|
6
6
|
const extension_1 = require("./extension");
|
|
7
7
|
function createConverter(config = {}) {
|
|
8
8
|
const { rootName = 'piral-slot' } = config;
|
|
@@ -10,11 +10,11 @@ function createConverter(config = {}) {
|
|
|
10
10
|
const convert = (root) => ({
|
|
11
11
|
mount(el, props, context, locals) {
|
|
12
12
|
locals.update = (props, context) => {
|
|
13
|
-
locals.destroy = (0,
|
|
13
|
+
locals.destroy = (0, web_1.render)(() => {
|
|
14
14
|
(0, solid_js_1.onCleanup)(() => {
|
|
15
15
|
el.innerHTML = '';
|
|
16
16
|
});
|
|
17
|
-
return (0,
|
|
17
|
+
return (0, web_1.createComponent)(root, Object.assign({ context }, props));
|
|
18
18
|
}, el);
|
|
19
19
|
};
|
|
20
20
|
locals.update(props, context);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "piral-solid",
|
|
3
|
-
"version": "0.15.9-beta.
|
|
3
|
+
"version": "0.15.9-beta.5435",
|
|
4
4
|
"description": "Plugin for integrating Solid components in Piral.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"piral",
|
|
@@ -64,11 +64,11 @@
|
|
|
64
64
|
"test": "echo \"Error: run tests from root\" && exit 1"
|
|
65
65
|
},
|
|
66
66
|
"devDependencies": {
|
|
67
|
-
"piral-core": "0.15.9-beta.
|
|
68
|
-
"solid-js": "^
|
|
67
|
+
"piral-core": "0.15.9-beta.5435",
|
|
68
|
+
"solid-js": "^1.7.3"
|
|
69
69
|
},
|
|
70
70
|
"peerDependencies": {
|
|
71
|
-
"solid-js": "^0.
|
|
71
|
+
"solid-js": "^1.0.0"
|
|
72
72
|
},
|
|
73
|
-
"gitHead": "
|
|
73
|
+
"gitHead": "9a36cc1b229556a4a0fcd7075cc51bdfd6190fe2"
|
|
74
74
|
}
|
package/src/converter.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ForeignComponent, BaseComponentProps } from 'piral-core';
|
|
2
2
|
import { Component, onCleanup } from 'solid-js';
|
|
3
|
-
import { render, createComponent } from 'solid-js/
|
|
3
|
+
import { render, createComponent } from 'solid-js/web';
|
|
4
4
|
import { createExtension } from './extension';
|
|
5
5
|
|
|
6
6
|
export interface SolidConverterOptions {
|