# @code-style/create-configs

> A script to create configuration files to conform to code style standards.

Latest version **2.0.0-35** (published 2025-09-09) · MIT license · 0 weekly downloads

## Install

```sh
npm install @code-style/create-configs
pnpm add @code-style/create-configs
yarn add @code-style/create-configs
bun add @code-style/create-configs
```

Provides the command `create-configs`.

## Health

**Score 70/100 (B)** — status: stable.

Positive: has types; esm support; no vulnerabilities; has provenance; high maintenance score; high quality score.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 2.0.0-35 |
| Published | 2025-09-09 |
| First published | 2024-03-19 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=18 |
| Dependencies | 9 |
| Unpacked size | 265.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 1 |
| Author | Louis Orleans |
| Maintainers | dudeofawesome |
| Keywords | style, lint, config, format, setup |

## Links

- npm: https://www.npmjs.com/package/@code-style/create-configs
- Repository: https://github.com/dudeofawesome/code-style
- Homepage: https://github.com/dudeofawesome/code-style/blob/main/packages/create-configs/README.md
- Issues: https://github.com/dudeofawesome/code-style/issues
- npm.io page: https://npm.io/package/@code-style/create-configs

## Dependencies (9)

- [yaml](https://npm.io/package/yaml.md) ^2.3.2
- [chalk](https://npm.io/package/chalk.md) ^5.3.0
- [json5](https://npm.io/package/json5.md) ^2.2.3
- [yargs](https://npm.io/package/yargs.md) ^17.7.2
- [prettier](https://npm.io/package/prettier.md) ^3.1.0
- [common-tags](https://npm.io/package/common-tags.md) ^1.8.2
- [@inquirer/prompts](https://npm.io/package/@inquirer/prompts.md) ^5.0.0
- [@npmcli/package-json](https://npm.io/package/@npmcli/package-json.md) ^5.1.0
- [@code-style/code-style](https://npm.io/package/@code-style/code-style.md) ^2.0.0-35

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

- 2.0.0-35 (latest) — 2025-09-09
- 2.0.0-34 — 2025-09-04
- 2.0.0-33 — 2025-09-04
- 2.0.0-32 — 2024-05-11
- 2.0.0-31 — 2024-05-11
- 2.0.0-30 — 2024-05-03
- 2.0.0-29 — 2024-05-03
- 2.0.0-28 — 2024-05-03
- 2.0.0-27 — 2024-04-14
- 2.0.0-26 — 2024-04-13
- 2.0.0-25 — 2024-03-20
- 2.0.0-24 — 2024-03-19

## README

# @code-style/create-configs

A script to create configuration files to conform to code style standards.

## Usage

1. Create your config files.

    ```
    $ npm init @code-style/configs
    ```

1. Answer the prompted questions.

1. Verify settings match the type of project you're working on.

    ESLint in particular has a bunch of settings that will vary based on the type of project you're working on.

### Consider adding some editor settings

-   VS Code

    Handled by this script

-   Vim

    ```vim
    let g:prettier#autoformat_config_present = 1
    let g:prettier#autoformat_require_pragma = 0
    ```

### Consider installing editor plugins

This will automatically apply formatting and linting to your files as you work.

-   VS Code

    Handled by this script

-   Vim
    -   https://github.com/prettier/vim-prettier
    -   https://github.com/editorconfig/editorconfig-vim
    -   https://github.com/vim-syntastic/syntastic
-   IntelliJ IDEA
    -   https://www.jetbrains.com/help/idea/prettier.html
    -   https://www.jetbrains.com/help/idea/editorconfig.html
    -   https://www.jetbrains.com/help/idea/eslint.html
-   Sublime Text
    -   https://packagecontrol.io/packages/JsPrettier
    -   https://packagecontrol.io/packages/EditorConfig
    -   https://github.com/SublimeLinter/SublimeLinter-eslint

### Formatting a pre-existing project

If you'd like to maintain git-blame information, you can use the following method (with varying amounts of success):

1. Make sure you've got a clean working tree
1. Run Prettier

    ```sh
    prettier -w .
    ```

1. Commit changes

    ````sh
    git add .
    git commit --author="Prettier (see commit msg) <software@iunu.com>" \
    -m "🎨 format with prettier (see message)" -m \
    'To see the original author of a line with `git blame`, use:

    ```sh
    git config blame.ignoreRevsFile .git-blame-ignore-revs
    ```

    This will configure git to ignore this commit when looking at history for `blame`.'
    ````

1. Add formatting commit hash to `.git-blame-ignore-revs`

    This makes `git blame` ignore the formatting commit so you can see the actual author of the line.

1. Commit `.git-blame-ignore-revs`

    ````sh
    git add .git-blame-ignore-revs
    git commit -m "🔧 add git-blame-ignore-revs" -m \
    'Run the following command to ignore the repo-wide prettier format

    ```sh
    git config blame.ignoreRevsFile .git-blame-ignore-revs
    ```'
    ````

1. Setup git to ignore the formatting commit

    ```sh
    git config blame.ignoreRevsFile .git-blame-ignore-revs
    ```

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