diff --git a/README.md b/README.md index 93ea85d..4dfc0d0 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,13 @@ Note: only the asynchronous API is supported, due to the limitations of having t ```js var randomBytes = require('react-native-randombytes') + +// synchronous API +// uses SJCL +var rand = randomBytes(4) + +// asynchronous API +// uses iOS-side SecRandomCopyBytes randomBytes(4, (err, bytes) => { console.log(bytes.toString('hex')) })