@ntnyq/prettier-config
Version:
Sharable prettier config of ntnyq.
72 lines (52 loc) • 1.44 kB
Markdown
# @ntnyq/prettier-config
[](https://github.com/ntnyq/prettier-config/actions)
[](https://www.npmjs.com/package/@ntnyq/prettier-config)
[](https://www.npmjs.com/package/@ntnyq/prettier-config)
[](https://github.com/ntnyq/prettier-config/blob/main/LICENSE)
My sharable prettier config.
## Install
```shell
npm install @ntnyq/prettier-config
```
```shell
yarn add @ntnyq/prettier-config
```
```shell
pnpm add @ntnyq/prettier-config
```
```shell
bun add @ntnyq/prettier-config
```
### Usage
Config in `prettier.config.mjs`:
### Basic usage
```mjs
// @ts-check
import { defineConfig } from '@ntnyq/prettier-config'
export default defineConfig()
```
### Custom options
```mjs
// @ts-check
import { defineConfig } from '@ntnyq/prettier-config'
export default defineConfig({
printWidth: 100,
trailingComma: 'none',
overrides: [
{
files: ['**/*.html'],
options: {
singleAttributePerLine: false,
},
},
{
files: ['**/*.{css,scss}'],
options: {
singleQuote: false,
},
},
],
})
```
## License
[MIT](./LICENSE) License © 2020-PRESENT [ntnyq](https://github.com/ntnyq)