@constela/start 1.2.0 → 1.2.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.
|
@@ -22,11 +22,7 @@ function initClient(options) {
|
|
|
22
22
|
getState: (name) => appInstance.getState(name),
|
|
23
23
|
setState: (name, value) => appInstance.setState(name, value),
|
|
24
24
|
subscribe: (name, fn) => {
|
|
25
|
-
|
|
26
|
-
return appInstance.subscribe(name, fn);
|
|
27
|
-
}
|
|
28
|
-
return () => {
|
|
29
|
-
};
|
|
25
|
+
return appInstance.subscribe(name, fn);
|
|
30
26
|
}
|
|
31
27
|
};
|
|
32
28
|
try {
|
|
@@ -47,10 +43,8 @@ function initClient(options) {
|
|
|
47
43
|
if (currentTheme) {
|
|
48
44
|
updateThemeClass(currentTheme);
|
|
49
45
|
}
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
cleanupFns.push(unsubscribeTheme);
|
|
53
|
-
}
|
|
46
|
+
const unsubscribeTheme = appInstance.subscribe("theme", updateThemeClass);
|
|
47
|
+
cleanupFns.push(unsubscribeTheme);
|
|
54
48
|
}
|
|
55
49
|
let destroyed = false;
|
|
56
50
|
return {
|
|
@@ -67,6 +61,9 @@ function initClient(options) {
|
|
|
67
61
|
},
|
|
68
62
|
getState(name) {
|
|
69
63
|
return appInstance.getState(name);
|
|
64
|
+
},
|
|
65
|
+
subscribe(name, fn) {
|
|
66
|
+
return appInstance.subscribe(name, fn);
|
|
70
67
|
}
|
|
71
68
|
};
|
|
72
69
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@constela/start",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.1",
|
|
4
4
|
"description": "Meta-framework for Constela applications",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -41,10 +41,10 @@
|
|
|
41
41
|
"unified": "^11.0.0",
|
|
42
42
|
"vite": "^6.0.0",
|
|
43
43
|
"@constela/compiler": "0.7.0",
|
|
44
|
-
"@constela/server": "3.0.0",
|
|
45
44
|
"@constela/router": "8.0.0",
|
|
45
|
+
"@constela/runtime": "0.10.1",
|
|
46
46
|
"@constela/core": "0.7.0",
|
|
47
|
-
"@constela/
|
|
47
|
+
"@constela/server": "3.0.0"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
50
|
"@types/mdast": "^4.0.4",
|