From 4257b8b710e7554911e0f709d18ea7e16928879e Mon Sep 17 00:00:00 2001 From: Daniel Sanchez Date: Fri, 3 Dec 2021 17:57:26 -0600 Subject: [PATCH 1/2] update example code snippet to json instead of js --- docs/linting/MONOREPO.md | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/docs/linting/MONOREPO.md b/docs/linting/MONOREPO.md index c135ae8cafab..b9e70a80eaad 100644 --- a/docs/linting/MONOREPO.md +++ b/docs/linting/MONOREPO.md @@ -56,21 +56,22 @@ If you've only got one, you should inspect the `include` paths. If it doesn't in The former doesn't always work for everyone if they've got a complex build, as adding more paths (like test paths) to `include` could break the build. In those cases we suggest creating a new config called `tsconfig.eslint.json`, that looks something like this: -```js title=".eslintrc.js" -module.exports = { +```jsonc title="tsconfig.eslint.json" +{ // extend your base config to share compilerOptions, etc - extends: './tsconfig.json', - compilerOptions: { + "extends": "./tsconfig.json", + "compilerOptions": { // ensure that nobody can accidentally use this config for a build - noEmit: true, + "noEmit": true }, - include: [ + "include": [ // whatever paths you intend to lint - 'src', - 'test', - 'tools', - ], -}; + "src", + "test", + "tools" + ] +} + ``` Ensure you update your `.eslintrc.js` to point at this new config file. From 58a7c071415db40f810e677298b8064bf75fd8f6 Mon Sep 17 00:00:00 2001 From: Brad Zacher Date: Mon, 6 Dec 2021 11:15:51 -0800 Subject: [PATCH 2/2] Update MONOREPO.md --- docs/linting/MONOREPO.md | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/linting/MONOREPO.md b/docs/linting/MONOREPO.md index b9e70a80eaad..2f8cbe15f349 100644 --- a/docs/linting/MONOREPO.md +++ b/docs/linting/MONOREPO.md @@ -71,7 +71,6 @@ In those cases we suggest creating a new config called `tsconfig.eslint.json`, t "tools" ] } - ``` Ensure you update your `.eslintrc.js` to point at this new config file.