flexium 0.12.8 → 0.12.9

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
@@ -80,18 +80,18 @@ Pass an async function to handle data fetching automatically.
80
80
 
81
81
  ```tsx
82
82
  function UserProfile({ id }) {
83
- const [user, refetch, isLoading, error] = state(async () => {
83
+ const [user, control] = state(async () => {
84
84
  const res = await fetch(`/api/users/${id}`);
85
85
  return res.json();
86
86
  });
87
87
 
88
- if (isLoading) return <div>Loading...</div>;
89
- if (error) return <div>Error!</div>;
88
+ if (control.loading) return <div>Loading...</div>;
89
+ if (control.error) return <div>Error!</div>;
90
90
 
91
91
  return (
92
92
  <div>
93
93
  <h1>{user.name}</h1>
94
- <button onclick={() => refetch()}>Reload</button>
94
+ <button onclick={() => control.refetch()}>Reload</button>
95
95
  </div>
96
96
  );
97
97
  }
@@ -101,7 +101,7 @@ function UserProfile({ id }) {
101
101
 
102
102
  ```tsx
103
103
  const [count, setCount] = state(1);
104
- const [double] = state(() => count * 2);
104
+ const [double] = state(() => count * 2, { deps: [count] });
105
105
  ```
106
106
 
107
107
  ### Array Keys & Params
package/dist/index.d.cts CHANGED
@@ -1,3 +1,3 @@
1
- declare const VERSION = "0.12.8";
1
+ declare const VERSION = "0.12.9";
2
2
 
3
3
  export { VERSION };
package/dist/index.d.ts CHANGED
@@ -1,3 +1,3 @@
1
- declare const VERSION = "0.12.8";
1
+ declare const VERSION = "0.12.9";
2
2
 
3
3
  export { VERSION };
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
- 'use strict';var o="0.12.8";exports.VERSION=o;//# sourceMappingURL=index.js.map
1
+ 'use strict';var o="0.12.9";exports.VERSION=o;//# sourceMappingURL=index.js.map
2
2
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/index.ts"],"names":["VERSION"],"mappings":"aAAO,IAAMA,CAAAA,CAAU","file":"index.js","sourcesContent":["export const VERSION = '0.12.8' // Bump version to signify rebuild\n"]}
1
+ {"version":3,"sources":["../src/index.ts"],"names":["VERSION"],"mappings":"aAAO,IAAMA,CAAAA,CAAU","file":"index.js","sourcesContent":["export const VERSION = '0.12.9' // Bump version to signify rebuild\n"]}
package/dist/index.mjs CHANGED
@@ -1,2 +1,2 @@
1
- var o="0.12.8";export{o as VERSION};//# sourceMappingURL=index.mjs.map
1
+ var o="0.12.9";export{o as VERSION};//# sourceMappingURL=index.mjs.map
2
2
  //# sourceMappingURL=index.mjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/index.ts"],"names":["VERSION"],"mappings":"AAAO,IAAMA,CAAAA,CAAU","file":"index.mjs","sourcesContent":["export const VERSION = '0.12.8' // Bump version to signify rebuild\n"]}
1
+ {"version":3,"sources":["../src/index.ts"],"names":["VERSION"],"mappings":"AAAO,IAAMA,CAAAA,CAAU","file":"index.mjs","sourcesContent":["export const VERSION = '0.12.9' // Bump version to signify rebuild\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "flexium",
3
- "version": "0.12.8",
3
+ "version": "0.12.9",
4
4
  "description": "A lightweight, signals-based UI framework with cross-platform renderers",
5
5
  "publishConfig": {
6
6
  "access": "public"