Documentation ¶
Overview ¶
Package randstr generates random strings (e.g. passwords), supporting unicode and emojis.
Index ¶
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Runes ¶
Runes returns a random array of runes, using only the runes given and the io.Reader as the source of randomness. For cryptographic randomness use crypto/rand's Reader.
func String ¶
String returns a random string of length, using only the runes given and the io.Reader as the source of randomness. For cryptographic randomness use crypto/rand's Reader.
Example ¶
package main import ( "crypto/rand" "4d63.com/randstr/lib/charset" "4d63.com/randstr/lib/randstr" ) func main() { _, _ = randstr.String(rand.Reader, charset.ASCII, 50) }
Output:
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.