Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions .eslintignore

This file was deleted.

58 changes: 0 additions & 58 deletions .eslintrc.json

This file was deleted.

10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,12 @@ gts lint *.ts

### Working with eslint

Under the covers, we use [eslint][eslint-url] to enforce the style guide and provide automated fixes, and [prettier][prettier-url] to re-format code. To use the shared `eslint` configuration, create an `.eslintrc` in your project directory, and extend the shared config:
Under the covers, we use [eslint][eslint-url] to enforce the style guide and provide automated fixes, and [prettier][prettier-url] to re-format code. To use the shared `eslint` configuration, create an `eslint.config.js` in your project directory, and extend the shared config:

```yml
---
extends:
- './node_modules/gts'
```js
module.exports = [
...require('gts'),
];
```

If you don't want to use the `gts` CLI, you can drop down to using the module as a basic `eslint` config, and just use the `eslint` cli:
Expand Down
6 changes: 6 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
'use strict';
const config = require('./src/index.js');
const ignores = require('./eslint.ignores.js');
const defineConfig = require('eslint/config').defineConfig;

module.exports = defineConfig([{ignores}, ...config]);
1 change: 1 addition & 0 deletions eslint.ignores.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module.exports = ['build/', '**/node_modules/', 'template/', 'test/fixtures/'];
Loading