compute method

String compute(
  1. String input
)

Computes a SHA-256 hash for the provided input.

Implementation

String compute(String input) {
  final bytes = utf8.encode(input);
  return sha256.convert(bytes).toString();
}