# simple-format

> sprintf with multiple arguments

Latest version **1.0.0** (published 2015-06-30) · MIT license · 0 weekly downloads

## Install

```sh
npm install simple-format
pnpm add simple-format
yarn add simple-format
bun add simple-format
```

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2015-06-30 |
| First published | 2015-06-30 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=0.10.0 |
| Dependencies | 2 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Ben Drucker |
| Maintainers | bendrucker |
| Keywords | sprintf, printf, format, string, print, util, format |

## Links

- npm: https://www.npmjs.com/package/simple-format
- Repository: https://github.com/bendrucker/simple-format
- Homepage: https://github.com/bendrucker/simple-format#readme
- Issues: https://github.com/bendrucker/simple-format/issues
- npm.io page: https://npm.io/package/simple-format

## Dependencies (2)

- [pff](https://npm.io/package/pff.md) ~1.0.0
- [to-array](https://npm.io/package/to-array.md) ~0.1.4

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 1.0.0 (latest) — 2015-06-30

## README

# simple-format [![Build Status](https://travis-ci.org/bendrucker/simple-format.svg?branch=master)](https://travis-ci.org/bendrucker/simple-format)

> Simple util.format replace that handles multiple arguments


## Install

```
$ npm install --save simple-format
```


## Usage

```js
var format = require('simple-format')
format('unicorns', '&', 'rainbows')
//=> unicorns & rainbows
format('%s & %s', 'unicorns', 'rainbows')
//=> unicorns & rainbows
```

## API

#### `format(messages...)` -> `string`

##### messages

Type: `string` (variadic)

Strings to format. Operates like [`util.format`](https://nodejs.org/api/util.html#util_util_format_format) which powers `console.log` in Node. If the first message has replacement tokens (e.g. *%s*), later arguments will be used as replacements. Otherwise, all arguments will be joined with a space.


## License

MIT © [Ben Drucker](http://bendrucker.me)

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