randomBytes function

Iterable<int> randomBytes(
  1. int length
)

Implementation

Iterable<int> randomBytes(int length) {
  final r = Random();
  return Iterable.generate(length, (i) => r.nextInt(255));
}