Skip to content

Commit

Permalink
Merge #11091
Browse files Browse the repository at this point in the history
11091: [sdk/nodejs] Avoid eslint error in VS Code r=justinvp a=justinvp

I often open VS Code in the root `pulumi/pulumi` directory, and when I do that and edit any `sdk/nodejs` files, eslint complains with:

> Parsing error: File '/users/user/go/src/github.com/pulumi/pulumi/tsconfig.json' not found.

This is because it looks for `tsconfig.json` in the current working directory by default. To fix this, `tsconfigRootDir` can be set in `.eslintrc.js`.

Co-authored-by: Justin Van Patten <jvp@justinvp.com>
  • Loading branch information
bors[bot] and justinvp committed Oct 20, 2022
2 parents b56aa58 + fe18b9a commit a7cea59
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions sdk/nodejs/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ module.exports = {
"parser": "@typescript-eslint/parser",
"parserOptions": {
"project": "tsconfig.json",
"tsconfigRootDir": __dirname,
"sourceType": "module"
},
"plugins": [
Expand Down

0 comments on commit a7cea59

Please sign in to comment.