# semistandard

> All the goodness of `feross/standard` with semicolons sprinkled on top.

Latest version **17.0.0** (published 2023-05-29) · MIT license · 0 weekly downloads

## Install

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

Provides the command `semistandard`.

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 17.0.0 |
| Published | 2023-05-29 |
| First published | 2015-01-27 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Node | ^12.22.0 \|\| ^14.17.0 \|\| >=16.0.0 |
| Dependencies | 9 |
| Unpacked size | 46.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1410 |
| Author | Feross Aboukhadijeh |
| Maintainers | jhiesey, bret, feross, flet, linusu, mafintosh, jprichardson, watson, raynos, toddbluhm, voxpelli |
| Keywords | JavaScript Standard Style, bikeshed, check, checker, code, code checker, code linter, code standards, code style, enforce, eslint, hint, jscs, jshint, lint, policy, quality, semicolon, simple, standard, standard style, style, style checker, style linter, verify |

## Links

- npm: https://www.npmjs.com/package/semistandard
- Repository: https://github.com/standard/semistandard
- Issues: https://github.com/standard/semistandard/issues
- Funding: https://github.com/sponsors/feross
- npm.io page: https://npm.io/package/semistandard

## Dependencies (9)

- [eslint](https://npm.io/package/eslint.md) ^8.20.0
- [eslint-plugin-n](https://npm.io/package/eslint-plugin-n.md) ^15.2.4
- [standard-engine](https://npm.io/package/standard-engine.md) ^15.0.0
- [eslint-plugin-react](https://npm.io/package/eslint-plugin-react.md) ^7.30.1
- [eslint-plugin-import](https://npm.io/package/eslint-plugin-import.md) ^2.26.0
- [eslint-plugin-promise](https://npm.io/package/eslint-plugin-promise.md) ^6.0.0
- [eslint-config-standard](https://npm.io/package/eslint-config-standard.md) 17.0.0
- [eslint-config-semistandard](https://npm.io/package/eslint-config-semistandard.md) ^17.0.0
- [eslint-config-standard-jsx](https://npm.io/package/eslint-config-standard-jsx.md) ^11.0.0

## Alternatives

- [eslint-plugin-sonarjs](https://npm.io/package/eslint-plugin-sonarjs.md) — 2.9M weekly downloads
- [eslint-config-expo](https://npm.io/package/eslint-config-expo.md) — 1.5M weekly downloads
- [@matter/protocol](https://npm.io/package/@matter/protocol.md) — 63.5K weekly downloads
- [@eventcatalog/linter](https://npm.io/package/@eventcatalog/linter.md) — 24.8K weekly downloads
- [@inrupt/eslint-config-base](https://npm.io/package/@inrupt/eslint-config-base.md) — 4.5K weekly downloads

## Recent versions

- 17.0.0 (latest) — 2023-05-29
- 9.0.0-beta.0 (beta) — 2016-07-25
- 6.0.0 (next) — 2015-06-03
- 16.0.1 — 2021-06-14
- 16.0.0 — 2020-10-29
- 15.0.0 — 2020-10-29
- 14.2.3 — 2020-07-25
- 14.2.2 — 2020-06-24
- 14.2.1 — 2020-06-24
- 14.2.0 — 2019-09-14
- 14.1.0 — 2019-09-04
- 14.0.1 — 2019-08-19
- 14.0.0 — 2019-08-19
- 13.0.1 — 2018-11-09
- 13.0.0 — 2018-11-06
- … 55 more at https://npm.io/package/semistandard/versions

## README

# JavaScript Semi-Standard Style
[![tests][tests-image]][tests-url]
[![npm][npm-image]][npm-url]
[![downloads][downloads-image]][downloads-url]

### One Semicolon for the Dark Lord on his dark throne

All the goodness of [standard/standard] with semicolons sprinkled on top.

## Install

```bash
npm install semistandard
```

## Rules

Importantly:

- **semicolons**
- Check [standard/standard] for the rest of the rules.

## Badge

Use this in one of your projects? Include one of these badges in your readme to
let people know that your code is using the standard style.

[![js-semistandard-style](https://raw.githubusercontent.com/standard/semistandard/master/badge.svg)](https://github.com/standard/semistandard)

```markdown
[![js-semistandard-style](https://raw.githubusercontent.com/standard/semistandard/master/badge.svg)](https://github.com/standard/semistandard)
```

[![js-semistandard-style](https://img.shields.io/badge/code%20style-semistandard-brightgreen.svg)](https://github.com/standard/semistandard)

```markdown
[![js-semistandard-style](https://img.shields.io/badge/code%20style-semistandard-brightgreen.svg)](https://github.com/standard/semistandard)
```

## Usage

The easiest way to use JavaScript Semi-Standard Style to check your code is to install it
globally as a Node command line program. To do so, simply run the following command in
your terminal (flag `-g` installs `semistandard` globally on your system, omit it if you want
to install in the current working directory):

```bash
npm install semistandard -g
```

After you've done that you should be able to use the `semistandard` program. The simplest use
case would be checking the style of all JavaScript files in the current working directory:

```
$ semistandard
Error: Use JavaScript Semi-Standard Style
  lib/torrent.js:950:11: Expected '===' and instead saw '=='.
```

### Editor plugins

- **Sublime users**: Try [SublimeLinter-contrib-semistandard](https://github.com/Flet/SublimeLinter-contrib-semistandard) for linting in your editor!
- **Atom users** - Install [linter-js-standard](https://atom.io/packages/linter-js-standard)
- **VSCode users** - Install [vscode-standardjs](https://marketplace.visualstudio.com/items?itemName=chenxsan.vscode-standardjs)

### What you might do if you're clever

1. Add it to `package.json`

  ```json
  {
    "name": "my-cool-package",
    "devDependencies": {
      "semistandard": "*"
    },
    "scripts": {
      "test": "semistandard && node my-normal-tests-littered-with-semicolons.js"
    }
  }
  ```

2. Check style automatically when you run `npm test`

  ```
  $ npm test
  Error: Code style check failed:
    lib/torrent.js:950:11: Expected '===' and instead saw '=='.
  ```

3. Never give style feedback on a pull request again! (unless it's about semicolons)

### Custom Parser
To use a custom parser, install it from npm (example: `npm install
babel-eslint`) and add this to your package.json:

```json
{
  "semistandard": {
    "parser": "babel-eslint"
  }
}
```

### [Vim](http://www.vim.org/)

Install **[Syntastic][vim-1]** and add these lines to `.vimrc`:

```vim
let g:syntastic_javascript_checkers=['standard']
let g:syntastic_javascript_standard_exec = 'semistandard'
```

For automatic formatting on save, add these two lines to `.vimrc`:

```vim
autocmd bufwritepost *.js silent !semistandard % --fix
set autoread
```

[vim-1]: https://github.com/scrooloose/syntastic

### Ignoring files

Just like in `standard`, The paths `node_modules/**`, `*.min.js`, `bundle.js`, `coverage/**`, hidden files/folders
(beginning with `.`), and all patterns in a project's root `.gitignore` file are
automatically excluded when looking for `.js` files to check.

Sometimes you need to ignore additional folders or specific minfied files. To do that, add
a `semistandard.ignore` property to `package.json`:

```json
"semistandard": {
  "ignore": [
    "**/out/",
    "/lib/select2/",
    "/lib/ckeditor/",
    "tmp.js"
  ]
}
```

### Make it look `snazzy`
If you want prettier output, just install the [`snazzy`](https://github.com/feross/snazzy) package and pipe `semistandard` to it:

```bash
$ semistandard --verbose | snazzy
```

See [standard/standard] for more information.

[tests-image]: https://github.com/standard/semistandard/actions/workflows/test.yml/badge.svg
[tests-url]: https://github.com/standard/semistandard/actions/workflows/test.yml
[npm-image]: https://img.shields.io/npm/v/semistandard.svg
[npm-url]: https://npmjs.org/package/semistandard
[downloads-image]: https://img.shields.io/npm/dm/semistandard.svg
[downloads-url]: https://npmjs.org/package/semistandard
[standard/standard]: https://github.com/standard/standard

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