UNPKG

smartdev

Version:

A development tool that watches for file changes and restarts Node.js apps automatically. Supports JavaScript, MJS, EJS, and CJS files.

14 lines (10 loc) 245 B
// lib/error-handler.js const errors = []; const logError = (error) => { errors.push(error); console.error(`Logged error: ${error}`); }; const getErrors = () => { return errors; }; module.exports = { logError, getErrors };