From b9ebd68d8d9cefe1b0b1281398a399702e73a3c9 Mon Sep 17 00:00:00 2001 From: David Joy Date: Fri, 5 Jul 2024 10:18:39 -0400 Subject: [PATCH] fix: setting project relative to .eslintrc.js MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit VSCode was having issues finding the tsconfig.json because frontend-base existed in a larger workspace, and so it was looking for it in the root of the workspace. This makes it look relative to the actual file trying to use it, which should work regardless of anyone’s workspace structure. --- .eslintrc.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.eslintrc.js b/.eslintrc.js index 1df05827..b552e54d 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,8 +1,10 @@ +const path = require('path'); + const { createConfig } = require('.'); module.exports = createConfig('eslint', { parserOptions: { - project: './tsconfig.json', + project: path.resolve(__dirname, './tsconfig.json'), }, rules: { 'no-console': 'off',