# prettier-elastic-vars

> Prettier (code formatter) with elastic vars formatting

Latest version **1.11.1** (published 2018-03-20) · MIT license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

```sh
npm install prettier-elastic-vars
pnpm add prettier-elastic-vars
yarn add prettier-elastic-vars
bun add prettier-elastic-vars
```

Provides the command `prettier-elastic-vars`.

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 1.11.1 |
| Published | 2018-03-20 |
| First published | 2017-05-10 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=4 |
| Dependencies | 0 |
| Unpacked size | 7.7 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | James Long |
| Maintainers | medikoo |

## Links

- npm: https://www.npmjs.com/package/prettier-elastic-vars
- Repository: https://github.com/medikoo/prettier-elastic-vars
- Homepage: https://github.com/medikoo/prettier-elastic-vars#readme
- Issues: https://github.com/medikoo/prettier-elastic-vars/issues
- npm.io page: https://npm.io/package/prettier-elastic-vars

## Recent versions

- 1.11.1 (latest) — 2018-03-20
- 1.11.0 — 2018-03-20
- 1.10.2 — 2018-01-11
- 1.10.1 — 2018-01-11
- 1.10.0 — 2018-01-11
- 1.9.2 — 2018-01-02
- 1.9.1 — 2018-01-02
- 1.9.0 — 2018-01-02
- 1.8.2 — 2018-01-02
- 1.8.1 — 2018-01-02
- 1.8.0 — 2018-01-02
- 1.0.2 — 2017-10-09
- 1.0.1 — 2017-05-11
- 1.0.0 — 2017-05-10

## README

# prettier-elastic-vars

## Fork of a [Prettier](https://github.com/prettier/prettier) tweaked to provide alternative formatting for `var`, `let` and `const` declarations

### Installation

	$ npm install prettier-elastic-vars

### Usage

```javascript
var prettier = require("prettier-elastic-vars");

// Same as with original prettier
prettier.format(src, options);
```

### Examples

<table>
<thead><tr><th>prettier</th><th>prettier-elastic-vars</th></thead>
<tbody>
<tr>
<td>
<pre><code>var eloBar = require("elo-bar"),
  foo = require("foo"),
  otherThing = require("other-thing");
</pre></code>
</td>
<td>
<pre><code>var eloBar     = require("elo-bar")
  , foo        = require("foo")
  , otherThing = require("other-thing");
</pre></code>
</td>
</tr>
<tr>
<td>
<pre><code>const eloBar = require("elo-bar"),
  foo = require("foo"),
  otherThing = require("other-thing");
</pre></code>
</td>
<td>
<pre><code>const eloBar     = require("elo-bar")
    , foo        = require("foo")
    , otherThing = require("other-thing");
</pre></code>
</td>
</tr>
</tbody>
</table>

### Test

	$ npm test

----

![Prettier Banner](https://raw.githubusercontent.com/prettier/prettier-logo/master/images/prettier-banner-light.png)

<h2 align="center">Opinionated Code Formatter</h2>

<p align="center">
  <em>
  JavaScript
  · Flow
  · TypeScript
  · CSS
  · SCSS
  · Less
  · JSX
  · Vue
  · GraphQL
  · JSON
  · Markdown
  · <a href="https://prettier.io/docs/en/plugins.html">
      Your favorite language?
    </a>
  </em>
</p>

<p align="center">
  <a href="https://gitter.im/jlongster/prettier">
    <img alt="Gitter" src="https://img.shields.io/gitter/room/jlongster/prettier.svg?style=flat-square">
  </a>
  <a href="https://travis-ci.org/prettier/prettier">
    <img alt="Travis" src="https://img.shields.io/travis/prettier/prettier/master.svg?style=flat-square">
  </a>
  <a href="https://codecov.io/gh/prettier/prettier">
    <img alt="Codecov" src="https://img.shields.io/codecov/c/github/prettier/prettier.svg?style=flat-square">
  </a>
  <a href="https://www.npmjs.com/package/prettier">
    <img alt="npm version" src="https://img.shields.io/npm/v/prettier.svg?style=flat-square">
  </a>
  <a href="https://www.npmjs.com/package/prettier">
    <img alt="monthly downloads" src="https://img.shields.io/npm/dm/prettier.svg?style=flat-square">
  </a>
  <a href="#badge">
    <img alt="code style: prettier" src="https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square">
  </a>
  <a href="https://twitter.com/PrettierCode">
    <img alt="Follow+Prettier+on+Twitter" src="https://img.shields.io/twitter/follow/prettiercode.svg?label=follow+prettier&style=flat-square">
  </a>
</p>

## Intro

Prettier is an opinionated code formatter. It enforces a consistent style by parsing your code and re-printing it with its own rules that take the maximum line length into account, wrapping code when necessary.

### Input

<!-- prettier-ignore -->
```js
foo(reallyLongArg(), omgSoManyParameters(), IShouldRefactorThis(), isThereSeriouslyAnotherOne());
```

### Output

```js
foo(
  reallyLongArg(),
  omgSoManyParameters(),
  IShouldRefactorThis(),
  isThereSeriouslyAnotherOne()
);
```

Prettier can be run [in your editor](http://prettier.io/docs/en/editors.html) on-save, in a [pre-commit hook](https://prettier.io/docs/en/precommit.html), or in [CI environments](https://prettier.io/docs/en/cli.html#list-different) to ensure your codebase has a consistent style without devs ever having to post a nit-picky comment on a code review ever again!

---

**[Documentation](https://prettier.io/docs/en/)**

<!-- prettier-ignore -->
[Install](https://prettier.io/docs/en/install.html) ·
[Options](https://prettier.io/docs/en/options.html) ·
[CLI](https://prettier.io/docs/en/cli.html) ·
[API](https://prettier.io/docs/en/api.html)

**[Playground](https://prettier.io/playground/)**

---

## Badge

Show the world you're using _Prettier_ → [![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier)

```md
[![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier)
```

## Contributing

See [CONTRIBUTING.md](CONTRIBUTING.md).

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