|
Last change
on this file was 9af201e, checked in by MBK <marija.karapandzova@…>, 12 days ago |
|
Fix frontend appearance
|
-
Property mode
set to
100644
|
|
File size:
444 bytes
|
| Line | |
|---|
| 1 | /**
|
|---|
| 2 | Generate a [cryptographically strong](https://en.m.wikipedia.org/wiki/Strong_cryptography) random string.
|
|---|
| 3 |
|
|---|
| 4 | @param length - Length of the returned string.
|
|---|
| 5 | @returns A [`hex`](https://en.wikipedia.org/wiki/Hexadecimal) string.
|
|---|
| 6 |
|
|---|
| 7 | @example
|
|---|
| 8 | ```
|
|---|
| 9 | import cryptoRandomString = require('crypto-random-string');
|
|---|
| 10 |
|
|---|
| 11 | cryptoRandomString(10);
|
|---|
| 12 | //=> '2cf05d94db'
|
|---|
| 13 | ```
|
|---|
| 14 | */
|
|---|
| 15 | declare function cryptoRandomString(length: number): string;
|
|---|
| 16 |
|
|---|
| 17 | export = cryptoRandomString;
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.