computeForDataSync static method
Computes CID for data (sync version).
Implementation
static CID computeForDataSync(Uint8List data, {String codec = 'raw'}) {
final digest = sha256.convert(data);
final mhInfo = Multihash.encode(
'sha2-256',
Uint8List.fromList(digest.bytes),
);
return CID.v1(codec, mhInfo);
}