@itwin/itwinui-react 2.11.0 → 2.11.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.
package/CHANGELOG.md
CHANGED
|
@@ -40,4 +40,7 @@ const useId = () => {
|
|
|
40
40
|
return React.useMemo(() => `iui-${uniqueValue}`, [uniqueValue]);
|
|
41
41
|
};
|
|
42
42
|
exports.useId = useId;
|
|
43
|
-
|
|
43
|
+
// This is needed to avoid bundlers trying to import non-existing export.
|
|
44
|
+
// Read more: https://github.com/webpack/webpack/issues/14814
|
|
45
|
+
const _React = React;
|
|
46
|
+
const useUniqueValue = (_a = _React.useId) !== null && _a !== void 0 ? _a : (() => (0, numbers_js_1.getRandomValue)(10));
|
|
@@ -13,4 +13,7 @@ export const useId = () => {
|
|
|
13
13
|
const uniqueValue = useUniqueValue();
|
|
14
14
|
return React.useMemo(() => `iui-${uniqueValue}`, [uniqueValue]);
|
|
15
15
|
};
|
|
16
|
-
|
|
16
|
+
// This is needed to avoid bundlers trying to import non-existing export.
|
|
17
|
+
// Read more: https://github.com/webpack/webpack/issues/14814
|
|
18
|
+
const _React = React;
|
|
19
|
+
const useUniqueValue = (_a = _React.useId) !== null && _a !== void 0 ? _a : (() => getRandomValue(10));
|