@radix-ui/react-use-layout-effect 0.1.1-rc.2 → 0.1.1-rc.20
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/index.d.ts.map +1 -1
- package/dist/index.js +37 -1
- package/dist/index.js.map +1 -1
- package/dist/index.module.js +21 -1
- package/dist/index.module.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"
|
|
1
|
+
{"mappings":";AAEA;;;;;;GAMG;AACH,OAAA,MAAM,6CAAkF,CAAC","sources":["packages/react/use-layout-effect/src/packages/react/use-layout-effect/src/useLayoutEffect.tsx","packages/react/use-layout-effect/src/packages/react/use-layout-effect/src/index.ts","packages/react/use-layout-effect/src/index.ts"],"sourcesContent":[null,null,"export * from './useLayoutEffect';\n"],"names":[],"version":3,"file":"index.d.ts.map"}
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,38 @@
|
|
|
1
|
-
var
|
|
1
|
+
var $caHyQ$react = require("react");
|
|
2
|
+
|
|
3
|
+
function $parcel$exportWildcard(dest, source) {
|
|
4
|
+
Object.keys(source).forEach(function(key) {
|
|
5
|
+
if (key === 'default' || key === '__esModule' || dest.hasOwnProperty(key)) {
|
|
6
|
+
return;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
Object.defineProperty(dest, key, {
|
|
10
|
+
enumerable: true,
|
|
11
|
+
get: function get() {
|
|
12
|
+
return source[key];
|
|
13
|
+
}
|
|
14
|
+
});
|
|
15
|
+
});
|
|
16
|
+
|
|
17
|
+
return dest;
|
|
18
|
+
}
|
|
19
|
+
function $parcel$export(e, n, v, s) {
|
|
20
|
+
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
|
|
21
|
+
}
|
|
22
|
+
var $ca21affb0542a8a4$exports = {};
|
|
23
|
+
|
|
24
|
+
$parcel$export($ca21affb0542a8a4$exports, "useLayoutEffect", () => $ca21affb0542a8a4$export$e5c5a5f917a5871c);
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* On the server, React emits a warning when calling `useLayoutEffect`.
|
|
28
|
+
* This is because neither `useLayoutEffect` nor `useEffect` run on the server.
|
|
29
|
+
* We use this safe version which suppresses the warning by replacing it with a noop on the server.
|
|
30
|
+
*
|
|
31
|
+
* See: https://reactjs.org/docs/hooks-reference.html#uselayouteffect
|
|
32
|
+
*/ const $ca21affb0542a8a4$export$e5c5a5f917a5871c = Boolean(globalThis === null || globalThis === void 0 ? void 0 : globalThis.document) ? $caHyQ$react.useLayoutEffect : ()=>{};
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
$parcel$exportWildcard(module.exports, $ca21affb0542a8a4$exports);
|
|
36
|
+
|
|
37
|
+
|
|
2
38
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"
|
|
1
|
+
{"mappings":";;;;;;;;;;;;;;;;;;;;;;;;ACAA;AAEA;;;;;;GAMA,CACA,MAAMC,yCAAe,GAAGC,OAAO,CAACC,UAAD,KAAA,IAAA,IAACA,UAAD,KAAA,KAAA,CAAA,GAAA,KAAA,CAAA,GAACA,UAAU,CAAEC,QAAb,CAAP,GAAgCJ,4BAAhC,GAAwD,IAAM,EAAtF,AAAA;;ADTA","sources":["packages/react/use-layout-effect/src/index.ts","packages/react/use-layout-effect/src/useLayoutEffect.tsx"],"sourcesContent":["export * from './useLayoutEffect';\n","import * as React from 'react';\n\n/**\n * On the server, React emits a warning when calling `useLayoutEffect`.\n * This is because neither `useLayoutEffect` nor `useEffect` run on the server.\n * We use this safe version which suppresses the warning by replacing it with a noop on the server.\n *\n * See: https://reactjs.org/docs/hooks-reference.html#uselayouteffect\n */\nconst useLayoutEffect = Boolean(globalThis?.document) ? React.useLayoutEffect : () => {};\n\nexport { useLayoutEffect };\n"],"names":["React","useLayoutEffect","Boolean","globalThis","document"],"version":3,"file":"index.js.map"}
|
package/dist/index.module.js
CHANGED
|
@@ -1,2 +1,22 @@
|
|
|
1
|
-
import
|
|
1
|
+
import {useLayoutEffect as $dxlwH$useLayoutEffect} from "react";
|
|
2
|
+
|
|
3
|
+
function $parcel$export(e, n, v, s) {
|
|
4
|
+
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
|
|
5
|
+
}
|
|
6
|
+
var $9f79659886946c16$exports = {};
|
|
7
|
+
|
|
8
|
+
$parcel$export($9f79659886946c16$exports, "useLayoutEffect", () => $9f79659886946c16$export$e5c5a5f917a5871c);
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* On the server, React emits a warning when calling `useLayoutEffect`.
|
|
12
|
+
* This is because neither `useLayoutEffect` nor `useEffect` run on the server.
|
|
13
|
+
* We use this safe version which suppresses the warning by replacing it with a noop on the server.
|
|
14
|
+
*
|
|
15
|
+
* See: https://reactjs.org/docs/hooks-reference.html#uselayouteffect
|
|
16
|
+
*/ const $9f79659886946c16$export$e5c5a5f917a5871c = Boolean(globalThis === null || globalThis === void 0 ? void 0 : globalThis.document) ? $dxlwH$useLayoutEffect : ()=>{};
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
export {$9f79659886946c16$export$e5c5a5f917a5871c as useLayoutEffect};
|
|
2
22
|
//# sourceMappingURL=index.module.js.map
|
package/dist/index.module.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"mappings":"
|
|
1
|
+
{"mappings":";;;;;;;;ACAA;AAEA;;;;;;GAMA,CACA,MAAMC,yCAAe,GAAGC,OAAO,CAACC,UAAD,KAAA,IAAA,IAACA,UAAD,KAAA,KAAA,CAAA,GAAA,KAAA,CAAA,GAACA,UAAU,CAAEC,QAAb,CAAP,GAAgCJ,sBAAhC,GAAwD,IAAM,EAAtF,AAAA;;ADTA","sources":["packages/react/use-layout-effect/src/index.ts","packages/react/use-layout-effect/src/useLayoutEffect.tsx"],"sourcesContent":["export * from './useLayoutEffect';\n","import * as React from 'react';\n\n/**\n * On the server, React emits a warning when calling `useLayoutEffect`.\n * This is because neither `useLayoutEffect` nor `useEffect` run on the server.\n * We use this safe version which suppresses the warning by replacing it with a noop on the server.\n *\n * See: https://reactjs.org/docs/hooks-reference.html#uselayouteffect\n */\nconst useLayoutEffect = Boolean(globalThis?.document) ? React.useLayoutEffect : () => {};\n\nexport { useLayoutEffect };\n"],"names":["React","useLayoutEffect","Boolean","globalThis","document"],"version":3,"file":"index.module.js.map"}
|