import 'dart:convert'; import 'package:crypto/crypto.dart'; String hashPassword(String pw) { var bytes = utf8.encode(pw); final password = sha256.convert(bytes).toString(); return password; }