Skip to content
This repository has been archived by the owner on Feb 2, 2024. It is now read-only.
/ ansi Public archive

πŸ“Ÿ Functional CLI ANSI formatter

License

Notifications You must be signed in to change notification settings

vangware/ansi

Repository files navigation

This repository's code was moved to lou.codes.


Coverage License NPM Version Open Issues

πŸ“Ÿ Functional CLI ANSI formatting functions.

Usage

πŸ“¦ Node

Install @vangware/ansi as a dependency:

pnpm add @vangware/ansi
# or
npm install @vangware/ansi
# or
yarn add @vangware/ansi

Import it and use it:

import { foregroundRed } from "@vangware/ansi";

foregroundRed`Hello world!`; // "Hello world!" in red text.

πŸ¦• Deno

Import @vangware/ansi using the npm: prefix, and use it directly:

import { foregroundRed } from "npm:@vangware/ansi";

foregroundRed`Hello world!`; // "Hello world!" in red text.

🌎 Browser

Import @vangware/ansi using esm.sh, and use it directly:

<script type="module">
	import { foregroundRed } from "https://esm.sh/@vangware/ansi";

	foregroundRed`Hello world!`; // "Hello world!" in red text.
</script>

Useful links