Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/comandeer/kreda
https://github.com/comandeer/kreda
Last synced: 24 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/comandeer/kreda
- Owner: Comandeer
- License: mit
- Created: 2024-03-07T21:35:30.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2024-04-16T23:23:08.000Z (7 months ago)
- Last Synced: 2024-09-18T12:22:18.138Z (about 2 months ago)
- Language: TypeScript
- Size: 217 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# kreda
[![npm](https://img.shields.io/npm/v/kreda.svg)](https://npmjs.com/package/kreda)
[Chalk-like](https://www.npmjs.com/package/chalk) API for [Node native terminal text styling](https://nodejs.org/api/util.html#utilstyletextformat-text).
⚠️ Requires Node >-21.7.0. The feature is marked as experimental – that means this package also should be treated as such.
## Installation
```bash
npm install kreda --save
```## Usage
```javascript
import kreda from 'kreda';console.log( kreda.blue( 'Some blue text' ) );
console.log( kreda.bgBlack.green.underline( 'Some green underlined text on a black background' ) );
console.log( kreda.blue( 'Hello,', 'world!' ) );
// ↑ The same as
console.log( kreda.blue( 'Hello, world!' ) );
```Refer to Node's documentation for [list of all available modifiers](https://nodejs.org/api/util.html#modifiers).
## LicenseSee [LICENSE](./LICENSE) file for details.