@uniflowed/web 0.23.0 → 0.25.0
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/cookie.js +4 -3
- package/package.json +4 -4
package/cookie.js
CHANGED
|
@@ -113,9 +113,10 @@ function readAll(): { [string]: string } {
|
|
|
113
113
|
* has no defined moment to take effect — the headers may already be on the wire
|
|
114
114
|
* — so a route handler or a server action is where that belongs.
|
|
115
115
|
*/
|
|
116
|
-
export function useCookie(
|
|
117
|
-
|
|
118
|
-
|
|
116
|
+
export function useCookie(name: string): [
|
|
117
|
+
string | null,
|
|
118
|
+
(next: string, options?: CookieOptions) => void,
|
|
119
|
+
] {
|
|
119
120
|
const [value, setValue] = React.useState<string | null>(() => {
|
|
120
121
|
const all = readAll();
|
|
121
122
|
return Object.hasOwn(all, name) ? all[name] : null;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uniflowed/web",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.25.0",
|
|
4
4
|
"description": "The primitives a web page is built from, for the Unified Toolchain for Flow.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -25,8 +25,8 @@
|
|
|
25
25
|
"!*.test.js"
|
|
26
26
|
],
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@uniflowed/core": "0.
|
|
29
|
-
"@uniflowed/hooks": "0.
|
|
30
|
-
"@uniflowed/react": "0.
|
|
28
|
+
"@uniflowed/core": "0.25.0",
|
|
29
|
+
"@uniflowed/hooks": "0.25.0",
|
|
30
|
+
"@uniflowed/react": "0.25.0"
|
|
31
31
|
}
|
|
32
32
|
}
|