const crypto = require('crypto'); const hash = crypto.createHash('sha256') .update('hello world') .digest('hex'); console.log(hash); // b94d27b9934d3e08a52e52d7da7dabfac484efe37a5380ee9088f7ace2efcde
Click Run to execute this code.