suvesh-terminal-text
v1.0.0
Published
Print big colorful text in terminal
Readme
suvesh-terminal-text
Print big, colorful, and fun text in your terminal! This package automatically selects the best font based on your text length and follows up with a random programmer joke or roast.
Features
- Big Colorful Text: Automatically uses
figletto generate large text banners. - Smart Font Selection: Adjusts the font size based on the number of words.
- Random Jokes & Roasts: Keeps things fun with a collection of programmer humor.
- Dual Module Support: Works seamlessly with both CommonJS (
require) and ES Modules (import).
Installation
npm install suvesh-terminal-textUsage
1. ES Modules (Recommended)
To use it in .mjs files or projects with "type": "module":
import terminalText from "suvesh-terminal-text";
// This will print the big text and then a random joke/roast
terminalText("Server Started");
// You can also import specific functions
import { terminalJoke } from "suvesh-terminal-text";
terminalJoke();2. CommonJS
To use it in standard .js files:
const terminalText = require("suvesh-terminal-text");
// This will print the big text and then a random joke/roast
terminalText("Hello World");
// Accessing the joke function directly
terminalText.joke();Preview
When you run terminalText("Hello"), you'll see something like this in your terminal:
_ _ _ _
| | | | | | |
| |__| | ___| | | ___
| __ |/ _ \ | |/ _ \
| | | | __/ | | (_) |
|_| |_|\___|_|_|\___/
😂 Programmer Joke:
Why do programmers always mix up Christmas and Halloween? Because Oct 31 == Dec 25.API
terminalText(text)
The default export. It's an async function that:
- Displays the provided
textin a large, randomly colored font. - Displays a random programmer joke or roast.
terminalJoke() (Named Export)
Displays only a random programmer joke or roast.
License
MIT
