dev-mindset-booster
v1.0.2
Published
Non-interactive developer mindset boosts and interview flashcards for Node.js workflows.
Downloads
78
Readme
dev-mindset-booster
Non-interactive developer mindset boosts and interview flashcards for Node.js workflows.
Install
npm install dev-mindset-boosterUsage
import { boost } from 'dev-mindset-booster';
await boost();CommonJS is supported as well:
const { boost } = require('dev-mindset-booster');
boost();Configure the cooldown in minutes and the flashcard categories:
await boost({
cooldown: 10,
categories: ['nodejs', 'javascript', 'systemdesign'],
});Supported categories are nodejs, javascript, db, systemdesign, and cloud. Each category contains 100 interview flashcards, and the package includes 100 technical mindset quotes.
When at least one selected category has flashcards, boost() always displays a flashcard. Quotes are used only when no eligible flashcards exist.
The package is safe to call from server startup or reload hooks. It uses .last-boost-time in the current working directory to avoid repeated output and fails silently if the cache cannot be read or written.
The package does not register global SIGINT or SIGTERM listeners because the consuming application owns its shutdown lifecycle. Handle those signals in the application and close its resources there:
const shutdown = async (signal) => {
console.log(`${signal} received; shutting down...`);
await server.close();
process.exitCode = 0;
};
process.once('SIGINT', () => void shutdown('SIGINT'));
process.once('SIGTERM', () => void shutdown('SIGTERM'));Development
npm install
npm test
npm run buildThe published package contains compiled files from dist/ and the README. TypeScript source files remain in the repository for development.
