Skip to content

Commit

Permalink
docs: Mention config migrator (#18561)
Browse files Browse the repository at this point in the history
  • Loading branch information
nzakas committed Jun 5, 2024
1 parent 469cb36 commit 518a35c
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions docs/src/use/configure/migration-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,20 @@ For reference information on these configuration formats, refer to the following
* [eslintrc configuration files](configuration-files-deprecated)
* [flat configuration files](configuration-files)

## Migrate Your Config File

To get started, use the [configuration migrator](https://npmjs.com/package/@eslint/migrate-config) on your existing configuration file (`.eslintrc`, `.eslintrc.json`, `.eslintrc.yml`), like this:

```shell
npx @eslint/migrate-config .eslintrc.json
```

This will create a starting point for your `eslint.config.js` file but is not guaranteed to work immediately without further modification. It will, however, do most of the conversion work mentioned in this guide automatically.

::: important
The configuration migrator doesn't yet work well for `.eslintrc.js` files. If you are using `.eslintrc.js`, the migration results in a config file that matches the evaluated output of your configuration and won't include any functions, conditionals, or anything other than the raw data represented in your configuration.
:::

## Start Using Flat Config Files

The flat config file format has been the default configuration file format since ESLint v9.0.0. You can start using the flat config file format without any additional configuration.
Expand Down

0 comments on commit 518a35c

Please sign in to comment.