1.0.0 • Published 9 months ago

colorful-logify v1.0.0

Weekly downloads
-
License
Apache-2.0
Repository
-
Last release
9 months ago

Colorful Logify

Colorful Logify is a Node.js package that allows you to easily add colorful and formatted text output to your command-line applications. Inspired by the text formatting used in games like Minecraft, Colorful Logify empowers you to create visually appealing and informative console messages.

Features

  • Colorful Messages: Enhance your CLI applications with colorful and eye-catching text that captures user attention.
  • Text Formatting: Apply various text formats such as bold, italic, underline, and more to emphasize your message.
  • Easy Integration: Simply incorporate Colorful Logify into your existing Node.js projects to instantly add text styling.
  • Minecraft-Inspired: Colorful Logify uses a similar syntax to Minecraft's text formatting codes for familiarity and ease of use.

Installation

You can install Colorful Logify via npm:

npm install colorful-logify

Usage

To use Colorful Logify in your project, follow these steps:

  1. Once installed, you can import the package into your Node.js script using the following line:
const { ColorLogger } = require('colorful-logify');
  1. Create an instance of ColorLogger by invoking its constructor:
const logger = new ColorLogger();
  1. With the instance created, you can now send styled messages to the console using the .send() method. To style your messages, you'll use special color and formatting codes, similar to those found in Minecraft's text formatting system.

Example usage (Method 1):

const example1 = new ColorLogger();
example1.send("&4Hello &b&lworld!");

Example usage (Method 2 - StaticStyle):

const StaticStyleLogger = ColorLogger.StaticStyle({
    styles: ["&6&n", "&b", "&m", "&5"]
});
const example2 = new StaticStyleLogger();
example2.send("Hello world!");

In both methods, the .send() method is used to print styled messages to the console. Experiment with different color and format codes to achieve the desired visual effects in your command-line output.

Remember, colorful-logify empowers you to bring a touch of color and styling to your command-line applications, enhancing their readability and engagement.

Color Codes and Formatting

Colorful Logify supports a range of color codes and formatting options. These codes are similar to those used in Minecraft for styling text. Below is a table of color codes and their descriptions:

CodeDescription
&0Black
&1Dark Blue
&2Dark Green
&3Dark Aqua
&4Dark Red
&5Dark Purple
&6Gold
&7Gray
&8Dark Gray
&9Blue
&aGreen
&bAqua
&cRed
&dLight Purple
&eYellow
&fWhite
&lBold
&oItalic
&nUnderline
&mStrikethrough
&rReset Format/Color

Feel free to experiment with different codes and create visually appealing messages for your command-line applications.

Contributing

Contributions are welcome! If you have any ideas for improvements or new features, feel free to reach out to us on Discord. You can contact us at JainaGam3r45 to discuss your ideas or to collaborate. We value your input and appreciate your contributions.

1.0.0

9 months ago