@hanzogui/use-force-update 4.3.1 → 102.0.0-rc.41-hanzoai.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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["isNodeMode","mod","__esModule","__defProp","target","value","enumerable","__toCommonJS","__copyProps","index_exports","__export","isServerSide","useForceUpdate","module","exports"],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAAA,UAAA,KAAAC,GAAA,KAAAA,GAAA,CAAAC,UAAA,GAAAC,SAAA,CAAAC,MAAA;EAAAC,KAAA,EAAAJ,GAAA;EAAAK,UAAA;AAAA,KAAAF,MAAA,EAAAH,GAAA;AAAA,IAAAM,YAAA,GAAkBN,GAAA,IAAAO,WAAA,CAAAL,SAAA;EAAAE,KAAA;AAAA,IAAAJ,GAAA;AAEX,IAAAQ,aAAM,IACX;AAEFC,QAAM,CAAAD,aAAa;EAACE,YAAA,EAAAA,CAAA,KAAAA,YAAA;EAEbC,cAAS,EAAAA,CAAA,KAAAA;AACd;AAGFC,MAAA,CAAAC,OAAA,GAAAP,YAAA,CAAAE,aAAA","ignoreList":[]}
|
package/dist/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","isServerSide","window","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":"AAAA,OAAOA,KAAA,MAAW;AAEX,MAAMC,YAAA,
|
|
1
|
+
{"version":3,"names":["React","isServerSide","window","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":"AAAA,OAAOA,KAAA,MAAW;AAEX,MAAMC,YAAA,GACX,OAAAC,MAAY;AAEd,MAAMC,IAAA,GAAOA,CAAA,KAAM;AAAC,SAAAC,eAAA;EAEb,OAAAH,YAAS,GAAAE,IAA6B,GAAAH,KAAA,CAAAK,UAAA,CAAAC,CAAA,IAAAC,IAAA,CAAAC,MAAA;AAC3C;AAGF,SAAAP,YAAA,EAAAG,cAAA","ignoreList":[]}
|
package/dist/esm/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","isServerSide","window","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":"AAAA,OAAOA,KAAA,MAAW;AAEX,MAAMC,YAAA,
|
|
1
|
+
{"version":3,"names":["React","isServerSide","window","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":"AAAA,OAAOA,KAAA,MAAW;AAEX,MAAMC,YAAA,GACX,OAAAC,MAAY;AAEd,MAAMC,IAAA,GAAOA,CAAA,KAAM;AAAC,SAAAC,eAAA;EAEb,OAAAH,YAAS,GAAAE,IAA6B,GAAAH,KAAA,CAAAK,UAAA,CAAAC,CAAA,IAAAC,IAAA,CAAAC,MAAA;AAC3C;AAGF,SAAAP,YAAA,EAAAG,cAAA","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","isServerSide","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":"AAAA,OAAOA,KAAA,MAAW;AAEX,IAAAC,YAAM,
|
|
1
|
+
{"version":3,"names":["React","isServerSide","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":"AAAA,OAAOA,KAAA,MAAW;AAEX,IAAAC,YAAM,QACX;AAEF,IAAAC,IAAM,YAAAA,CAAA,EAAa;AAAC,SAAAC,eAAA;EAEb,OAAAF,YAAS,GAAAC,IAA6B,GAAAF,KAAA,CAAAI,UAAA,WAAAC,CAAA;IAC3C,OAAOC,IAAA,CAAAC,MAAA;EAGT","ignoreList":[]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hanzogui/use-force-update",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "102.0.0-rc.41-hanzoai.1",
|
|
4
4
|
"gitHead": "a49cc7ea6b93ba384e77a4880ae48ac4a5635c14",
|
|
5
5
|
"files": [
|
|
6
6
|
"src",
|
|
@@ -28,13 +28,13 @@
|
|
|
28
28
|
"access": "public"
|
|
29
29
|
},
|
|
30
30
|
"scripts": {
|
|
31
|
-
"build": "
|
|
32
|
-
"watch": "
|
|
33
|
-
"clean": "
|
|
34
|
-
"clean:build": "
|
|
31
|
+
"build": "hanzogui-build",
|
|
32
|
+
"watch": "hanzogui-build --watch",
|
|
33
|
+
"clean": "hanzogui-build clean",
|
|
34
|
+
"clean:build": "hanzogui-build clean:build"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
|
-
"@hanzogui/build": "
|
|
37
|
+
"@hanzogui/build": "102.0.0-rc.41-hanzoai.1",
|
|
38
38
|
"react": ">=19"
|
|
39
39
|
},
|
|
40
40
|
"peerDependencies": {
|
package/src/index.ts
CHANGED
package/types/index.d.ts.map
CHANGED
|
@@ -6,6 +6,6 @@
|
|
|
6
6
|
],
|
|
7
7
|
"version": 3,
|
|
8
8
|
"sourcesContent": [
|
|
9
|
-
"import React from 'react'\n\nexport const isServerSide: boolean =\n process.env.
|
|
9
|
+
"import React from 'react'\n\nexport const isServerSide: boolean =\n process.env.TAMAGUI_TARGET === 'web' && typeof window === 'undefined'\n\nconst idFn = () => {}\n\nexport function useForceUpdate(): () => void {\n return isServerSide\n ? idFn\n : (React.useReducer((x) => Math.random(), 0)[1] as () => void)\n}\n"
|
|
10
10
|
]
|
|
11
11
|
}
|