@tamagui/use-force-update
Advanced tools
Comparing version 1.89.26 to 1.89.27-1708112217600
@@ -22,7 +22,8 @@ "use strict"; | ||
module.exports = __toCommonJS(src_exports); | ||
var import_react = require("react"); | ||
const isServerSide = !1, idFn = () => { | ||
var import_react = require("react"), isServerSide = !1, idFn = function() { | ||
}; | ||
function useForceUpdate() { | ||
return isServerSide ? idFn : (0, import_react.useReducer)((x) => Math.random(), 0)[1]; | ||
return isServerSide ? idFn : (0, import_react.useReducer)(function(x) { | ||
return Math.random(); | ||
}, 0)[1]; | ||
} | ||
@@ -29,0 +30,0 @@ // Annotate the CommonJS export names for ESM import in node: |
import { useReducer } from "react"; | ||
const isServerSide = !1, idFn = () => { | ||
var isServerSide = !1, idFn = function() { | ||
}; | ||
function useForceUpdate() { | ||
return isServerSide ? idFn : useReducer((x) => Math.random(), 0)[1]; | ||
return isServerSide ? idFn : useReducer(function(x) { | ||
return Math.random(); | ||
}, 0)[1]; | ||
} | ||
@@ -7,0 +9,0 @@ export { |
{ | ||
"name": "@tamagui/use-force-update", | ||
"version": "1.89.26", | ||
"version": "1.89.27-1708112217600", | ||
"types": "./types/index.d.ts", | ||
@@ -30,3 +30,3 @@ "main": "dist/cjs", | ||
"devDependencies": { | ||
"@tamagui/build": "1.89.26", | ||
"@tamagui/build": "1.89.27-1708112217600", | ||
"react": "^18.2.0" | ||
@@ -33,0 +33,0 @@ }, |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7283
100
2