nhb-express
Version:
Minimal Express + TypeScript scaffolder with modular structure and flexible stack choices.
13 lines (8 loc) • 291 B
JavaScript
// @ts-check
import { randomBytes } from 'crypto';
/**
* * Generates a random secret key for use in the application (e.g. jwt secrets).
* * Run `node secret.mjs` in the terminal opened in the project directory.
*/
const secret = randomBytes(64).toString('hex');
console.info(secret);