4 lines
141 B
JavaScript
4 lines
141 B
JavaScript
|
import { createHash } from 'crypto';
|
||
|
const digest = (algorithm, data) => createHash(algorithm).update(data).digest();
|
||
|
export default digest;
|