# eslint-config-swift

> eslint config used by Swift for frontend apps; based on airbnb's eslint config, but stricter.

Latest version **1.2.1** (published 2017-11-03) · MIT license · 0 weekly downloads

## Install

```sh
npm install eslint-config-swift
pnpm add eslint-config-swift
yarn add eslint-config-swift
bun add eslint-config-swift
```

## 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.2.1 |
| Published | 2017-11-03 |
| First published | 2016-09-01 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Joshua Gross |
| Maintainers | mfine, tonyd256, ljbade |
| Keywords | eslint, eslintconfig, swift, es6, javascript |

## Links

- npm: https://www.npmjs.com/package/eslint-config-swift
- Repository: https://github.com/swift-nav/eslint-config-swift
- Homepage: https://github.com/swift-nav/eslint-config-swift#readme
- Issues: https://github.com/swift-nav/eslint-config-swift/issues
- npm.io page: https://npm.io/package/eslint-config-swift

## 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

- 1.2.1 (latest) — 2017-11-03
- 1.2.0 — 2017-09-22
- 1.1.0 — 2017-08-04
- 1.0.5 — 2016-10-03
- 1.0.4 — 2016-10-03
- 1.0.3 — 2016-09-01
- 1.0.2 — 2016-09-01
- 1.0.1 — 2016-09-01
- 1.0.0 — 2016-09-01

## README

# eslint-config-swift
eslint config used by Swift for frontend apps; based on airbnb's eslint config, but stricter.

## Usage

```shell
npm install --save-dev eslint-config-swift
```

Then you need to install plugins required for our config and `airbnb`'s:

```shell
(
  export PKG=eslint-config-swift;
  npm info "$PKG" peerDependencies --json | command sed 's/[\{\},]//g ; s/: /@/g' | xargs npm install --save-dev "$PKG"
  export PKG=eslint-config-airbnb;
  npm info "$PKG" peerDependencies --json | command sed 's/[\{\},]//g ; s/: /@/g' | xargs npm install --save-dev "$PKG"
  export PKG=eslint-config-airbnb-base;
  npm info "$PKG" peerDependencies --json | command sed 's/[\{\},]//g ; s/: /@/g' | xargs npm install --save-dev "$PKG"
)
```

In your own `.eslintrc`, you can include the "universal" config for React/Redux apps or "electron" for Electron apps:

```
{
  "extends": "swift/universal"
}
```

or 

```
{
  "extends": "swift/electron"
}
```

And you probably want this in your `package.json`:

```json
{
  "scripts": {
    ...
    "lint": "eslint -c .eslintrc --ext .jsx,.js list of source directories"
    ...
  }
}
```

## webpack resolution

For the webpack import resolver to work, `webpack.config.js` must be in the filesystem adjacent to your `package.json`.

You probably want it to look something like this:

```javascript
// here for eslint-import-resolver-webpack
require('babel-register');
module.exports = require('./webpack.config.development.js');
```

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