Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/simenandre/prettier-config

Small, reusable, opinionated Prettier configuration
https://github.com/simenandre/prettier-config

prettier prettier-config

Last synced: about 1 month ago
JSON representation

Small, reusable, opinionated Prettier configuration

Awesome Lists containing this project

README

        

# @simenandre/prettier

Reusable prettier config.

## Installation

```bash
yarn add --dev @simenandre/prettier
```

or

```bash
pnpm add --save-dev @simenandre/prettier
```

## Usage

Add a key in your **package.json** file.

```
"prettier": "@simenandre/prettier"
```

**OR**

Create a **.prettierrc** , **.prettierrc.yaml** , **.prettierrc.yml** or
**.prettierrc.json** file and export a string.

```
"@simenandre/prettier"
```

**OR**

Create a **prettier.config.js** or **.prettierrc.js** file and export an object.

```
module.exports = {
...require("@simenandre/prettier"),
tabWidth: 2,
};
```

## Thanks

Most of this code is based on https://github.com/devsht/prettier-config.