@tamagui/use-force-update 2.1.0 → 2.2.0-1781071309197
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/dist/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","isServerSide","window","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["
|
|
1
|
+
{"version":3,"names":["React","isServerSide","window","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["index.mjs"],"sourcesContent":["import React from \"react\";\n\nconst isServerSide = typeof window === \"undefined\";\nconst idFn = () => {};\nfunction useForceUpdate() {\n\treturn isServerSide ? idFn : React.useReducer((x) => Math.random(), 0)[1];\n}\n\nexport { isServerSide, useForceUpdate };"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AAEzB,MAAMC,YAAY,GAAG,OAAOC,MAAM,KAAK,WAAW;AAClD,MAAMC,IAAI,GAAGA,CAAA,KAAM,CAAC,CAAC;AACrB,SAASC,cAAcA,CAAA,EAAG;EACzB,OAAOH,YAAY,GAAGE,IAAI,GAAGH,KAAK,CAACK,UAAU,CAAEC,CAAC,IAAKC,IAAI,CAACC,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;AAC1E;AAEA,SAASP,YAAY,EAAEG,cAAc","ignoreList":[]}
|
package/dist/esm/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","isServerSide","window","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["
|
|
1
|
+
{"version":3,"names":["React","isServerSide","window","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["index.mjs"],"sourcesContent":["import React from \"react\";\n\nconst isServerSide = typeof window === \"undefined\";\nconst idFn = () => {};\nfunction useForceUpdate() {\n\treturn isServerSide ? idFn : React.useReducer((x) => Math.random(), 0)[1];\n}\n\nexport { isServerSide, useForceUpdate };"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AAEzB,MAAMC,YAAY,GAAG,OAAOC,MAAM,KAAK,WAAW;AAClD,MAAMC,IAAI,GAAGA,CAAA,KAAM,CAAC,CAAC;AACrB,SAASC,cAAcA,CAAA,EAAG;EACzB,OAAOH,YAAY,GAAGE,IAAI,GAAGH,KAAK,CAACK,UAAU,CAAEC,CAAC,IAAKC,IAAI,CAACC,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;AAC1E;AAEA,SAASP,YAAY,EAAEG,cAAc","ignoreList":[]}
|
package/dist/esm/index.native.js
CHANGED
|
@@ -2,7 +2,7 @@ import React from "react";
|
|
|
2
2
|
var isServerSide = false;
|
|
3
3
|
var idFn = function () {};
|
|
4
4
|
function useForceUpdate() {
|
|
5
|
-
return
|
|
5
|
+
return false ? idFn : React.useReducer(function (x) {
|
|
6
6
|
return Math.random();
|
|
7
7
|
}, 0)[1];
|
|
8
8
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","isServerSide","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["
|
|
1
|
+
{"version":3,"names":["React","isServerSide","idFn","useForceUpdate","useReducer","x","Math","random"],"sources":["index.native.js"],"sourcesContent":["import React from \"react\";\n\nvar isServerSide = false;\nvar idFn = function() {};\nfunction useForceUpdate() {\n\treturn false ? idFn : React.useReducer(function(x) {\n\t\treturn Math.random();\n\t}, 0)[1];\n}\n\nexport { isServerSide, useForceUpdate };"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AAEzB,IAAIC,YAAY,GAAG,KAAK;AACxB,IAAIC,IAAI,GAAG,SAAAA,CAAA,EAAW,CAAC,CAAC;AACxB,SAASC,cAAcA,CAAA,EAAG;EACzB,OAAO,KAAK,GAAGD,IAAI,GAAGF,KAAK,CAACI,UAAU,CAAC,UAASC,CAAC,EAAE;IAClD,OAAOC,IAAI,CAACC,MAAM,CAAC,CAAC;EACrB,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;AACT;AAEA,SAASN,YAAY,EAAEE,cAAc","ignoreList":[]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tamagui/use-force-update",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.2.0-1781071309197",
|
|
4
4
|
"gitHead": "a49cc7ea6b93ba384e77a4880ae48ac4a5635c14",
|
|
5
5
|
"files": [
|
|
6
6
|
"src",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"clean:build": "tamagui-build clean:build"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
|
-
"@tamagui/build": "2.
|
|
37
|
+
"@tamagui/build": "2.2.0-1781071309197",
|
|
38
38
|
"react": ">=19"
|
|
39
39
|
},
|
|
40
40
|
"peerDependencies": {
|