# nodesplash

> 🌊 port of qdm12/gosplash to TypeScript

Latest version **0.1.1** (published 2021-12-14) · MIT license · 0 weekly downloads

## Install

```sh
npm install nodesplash
pnpm add nodesplash
yarn add nodesplash
bun add nodesplash
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.1 |
| Published | 2021-12-14 |
| First published | 2021-12-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 1 |
| Unpacked size | 34 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Max Isom |
| Maintainers | codetheweb |
| Keywords | 🌊, log, banner, splash, console |

## Links

- npm: https://www.npmjs.com/package/nodesplash
- Repository: https://github.com/codetheweb/nodesplash
- Homepage: https://github.com/codetheweb/nodesplash#readme
- Issues: https://github.com/codetheweb/nodesplash/issues
- npm.io page: https://npm.io/package/nodesplash

## Dependencies (1)

- [grapheme-splitter](https://npm.io/package/grapheme-splitter.md) ^1.0.4

## Alternatives

- [cli-color](https://npm.io/package/cli-color.md) — 3.4M weekly downloads
- [log](https://npm.io/package/log.md) — 1.3M weekly downloads
- [logstash-client](https://npm.io/package/logstash-client.md) — 4.5K weekly downloads
- [@nocobase/plugin-logger](https://npm.io/package/@nocobase/plugin-logger.md) — 2.0K weekly downloads
- [child-process-debug](https://npm.io/package/child-process-debug.md) — 695 weekly downloads

## Recent versions

- 0.1.1 (latest) — 2021-12-14
- 0.1.0 — 2021-12-14

## README

# 🌊 NodeSplash [![codecov](https://codecov.io/gh/codetheweb/nodesplash/branch/master/graph/badge.svg?token=BXZ22G570I)](https://codecov.io/gh/codetheweb/nodesplash)

Library to show log lines at the start of a program.

Direct port of [qdm12](https://github.com/qdm12)'s excellent [GoSplash](https://github.com/qdm12/gosplash) library.

For example, this

```typescript
import {makeLines} from "nodesplash";

console.log(makeLines({
    separator: '=',
    user: 'codetheweb',
    repository: 'nodesplash',
    emails: ['hi@maxisom.me'],
    version: 'v1.1.1',
    commit: 'c892ef2',
    buildDate: new Date('7/13/2021'),
    paypalUser: 'codetheweb',
    githubSponsor: 'codetheweb'
}).join('\n'));
```

will result in this:

```log
========================================
========================================
============== nodesplash ==============
========================================
=========== Made with ❤️ by ============
==== https://github.com/codetheweb =====
========================================
========================================

Running version v1.1.1 built on 7/13/2021 (commit c892ef2)

🔧 Need help? https://github.com/codetheweb/nodesplash/discussions/new
🐛 Bug? https://github.com/codetheweb/nodesplash/issues/new
✨ New feature? https://github.com/codetheweb/nodesplash/issues/new
☕ Discussion? https://github.com/codetheweb/nodesplash/discussions/new
💻 Email? hi@maxisom.me
💰 Help me? https://www.paypal.me/codetheweb https://github.com/sponsors/codetheweb
```

## Usage

`yarn add nodesplash` or `npm i nodesplash -s`. Then:

- `const {makeLines} = require('nodesplash')` for JavaScript or
- `import {makeLines} from 'nodesplash'` for TypeScript.

All settings:

```typescript
interface Settings {
  // Formatting settings
  lineLength?: number;   // defaults to 40
  separator?: string;    // defaults to '='
  madeByPrefix?: string; // defaults to 'Made with ❤️ by '

  // Project information
  rootURL?: string;   // defaults to https://github.com
  user?: string;
  repository?: string;
  authors?: string[]; // defaults to `${rootURL}/${user}`
  emails?: string[];

  // Program information
  version?: string;   // defaults to 'unknown'
  commit?: string;    // defaults to 'unknown'
  buildDate?: Date;   // defaults to 'unknown date'
  announcement?: string;
  announceExp?: Date; // don't include to disable expiration

  // Sponsor information
  paypalUser?: string;
  githubSponsor?: string;
}
```

---
_Source: https://npm.io/package/nodesplash · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
