# title

> Capitalize your titles properly

Latest version **4.0.1** (published 2024-11-20) · MIT license · 0 weekly downloads

## Install

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

Provides the command `title`.

## Health

**Score 50/100 (C)** — status: stable.

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

Warnings: low downloads.

Negative: stale.

## Facts

| | |
|---|---|
| Version | 4.0.1 |
| Published | 2024-11-20 |
| First published | 2013-01-16 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM |
| Dependencies | 3 |
| Unpacked size | 14.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 622 |
| Author | leo |
| Maintainers | leerobinson |
| Keywords | title, capitalize, chicago, manual, of, style |

## Links

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

## Dependencies (3)

- [arg](https://npm.io/package/arg.md) ^5.0.0
- [chalk](https://npm.io/package/chalk.md) ^5.0.0
- [clipboardy](https://npm.io/package/clipboardy.md) ^4.0.0

## Recent versions

- 4.0.1 (latest) — 2024-11-20
- 4.0.0 — 2024-11-19
- 3.5.3 — 2022-08-22
- 3.5.2 — 2022-08-11
- 3.5.1 — 2022-08-09
- 3.5.0 — 2022-08-09
- 3.4.4 — 2022-02-12
- 3.4.3 — 2021-03-31
- 3.4.2 — 2020-03-30
- 3.4.1 — 2019-01-22
- 3.4.0 — 2018-10-05
- 3.3.2 — 2018-08-06
- 3.3.1 — 2018-07-11
- 3.3.0 — 2018-05-12
- 3.2.0 — 2018-02-06
- … 5 more at https://npm.io/package/title/versions

## README

# Title

This package correctly capitalizes your titles as per [The Chicago Manual of Style](http://www.chicagomanualofstyle.org/home.html).

## Usage

Install the package:

```bash
pnpm add title
```

Then, import it and convert any input text:

```js
import title from 'title'

title('tHe cHicaGo maNual oF StyLe')

// Will result in:
// "The Chicago Manual of Style"
```

You can pass words that should be capitalized as specified:

```js
title('FaCEbook is great', {
  special: [ 'facebook' ]
})

// Will result in:
// "facebook is great"
```

### Command Line

You can also convert titles in the command line. Install the package globally:

```bash
pnpm add -g title
```

Next, run it:

```bash
title "tHe cHicaGo maNual oF StyLe"

# Will result in:
# "The Chicago Manual of Style"
```

To see all available options, run:

```bash
title -h
```

## Contributing

1. [Fork](https://help.github.com/articles/fork-a-repo/) this repository to your own GitHub account and then [clone](https://help.github.com/articles/cloning-a-repository/) it to your local device
2. Uninstall `title` if it's already installed: `pnpm remove -g title`
3. Link it to the global module directory: `pnpm link`

After that, you can use the `title` command everywhere.

## Original Authors

- Leo Lamprecht ([@leo](https://x.com/leo))
- Josh Junon ([@Qix-](https://github.com/Qix-))

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