From 5f58b43aa4fabee56fb8f75756f70f407a58745c Mon Sep 17 00:00:00 2001 From: Aaron Faanes Date: Wed, 4 Dec 2024 19:38:16 -0800 Subject: [PATCH] docs: Ensure link to getrandomvalues-not-supported is maintained (#844) --- README.md | 7 ++++++- README_js.md | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2210f85d..5c62afb5 100644 --- a/README.md +++ b/README.md @@ -490,7 +490,12 @@ Prior to `uuid@11`, it was possible for `options` state to interfere with the in ## Known issues -### React Native / Expo + +### "getRandomValues() not supported" + +This error occurs in environments where the standard [`crypto.getRandomValues()`](https://developer.mozilla.org/en-US/docs/Web/API/Crypto/getRandomValues) API is not supported. This issue can be resolved by adding an appropriate polyfill: + +#### React Native / Expo 1. Install [`react-native-get-random-values`](https://github.com/LinusU/react-native-get-random-values#readme) 1. Import it _before_ `uuid`. Since `uuid` might also appear as a transitive dependency of some other imports it's safest to just import `react-native-get-random-values` as the very first thing in your entry point: diff --git a/README_js.md b/README_js.md index a66ebc59..dbb01188 100644 --- a/README_js.md +++ b/README_js.md @@ -498,7 +498,12 @@ Prior to `uuid@11`, it was possible for `options` state to interfere with the in ## Known issues -### React Native / Expo + +### "getRandomValues() not supported" + +This error occurs in environments where the standard [`crypto.getRandomValues()`](https://developer.mozilla.org/en-US/docs/Web/API/Crypto/getRandomValues) API is not supported. This issue can be resolved by adding an appropriate polyfill: + +#### React Native / Expo 1. Install [`react-native-get-random-values`](https://github.com/LinusU/react-native-get-random-values#readme) 1. Import it _before_ `uuid`. Since `uuid` might also appear as a transitive dependency of some other imports it's safest to just import `react-native-get-random-values` as the very first thing in your entry point: