1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-11-21 11:35:34 +01:00

Multi root workspace tweaks (#2858)

* Ignore jest for workspaces without tests (for now)

* Add jest as recommended extension

* Set eslint and prettier file paths

We can't do this on a multi-folder workspace level because the
path depths are not identical between folders

* fix tsconfig extends for

* Simplify bitwarden-licensed web tsconfig

This tsconfig isn't needed to build, since we do that through webpack
and the web client. It's only needed as hints to IDEs

* Remove unintended change

* linter
This commit is contained in:
Matt Gibson 2022-06-13 21:39:36 -05:00 committed by GitHub
parent b92685dcd9
commit c4ff8f99dc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 81 additions and 57 deletions

6
apps/browser/.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,6 @@
{
"eslint.options": {
"ignorePath": "${workspaceFolder}/../../../.eslintIgnore"
},
"prettier.ignorePath": "${workspaceFolder}/../../../.prettierignore"
}

View File

@ -6,5 +6,9 @@
"webpack://?:*/*": "${workspaceFolder}/*",
"webpack://@bitwarden/cli/*": "${workspaceFolder}/*"
}
}
},
"eslint.options": {
"ignorePath": "${workspaceFolder}/../../../.eslintIgnore"
},
"prettier.ignorePath": "${workspaceFolder}/../../../.prettierignore"
}

6
apps/desktop/.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,6 @@
{
"eslint.options": {
"ignorePath": "${workspaceFolder}/../../../.eslintIgnore"
},
"prettier.ignorePath": "${workspaceFolder}/../../../.prettierignore"
}

6
apps/web/.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,6 @@
{
"eslint.options": {
"ignorePath": "${workspaceFolder}/../../../.eslintIgnore"
},
"prettier.ignorePath": "${workspaceFolder}/../../../.prettierignore"
}

View File

@ -0,0 +1,6 @@
{
"eslint.options": {
"ignorePath": "${workspaceFolder}/../../../.eslintIgnore"
},
"prettier.ignorePath": "${workspaceFolder}/../../../.prettierignore"
}

View File

@ -1,27 +1,3 @@
{
"extends": "../../apps/web/jslib/shared/tsconfig",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"tldjs": ["../../apps/web/jslib/common/src/misc/tldjs.noop"],
"jslib-common/*": ["../../apps/web/jslib/common/src/*"],
"jslib-angular/*": ["../../apps/web/jslib/angular/src/*"],
"@bitwarden/components": ["../../apps/web/jslib/components/src"],
"src/*": ["../../apps/web/src/*"]
}
},
"angularCompilerOptions": {
"preserveWhitespaces": true
},
"files": [
"../../apps/web/src/app/polyfills.ts",
"../../apps/web/src/app/main.ts",
"src/app/main.ts"
],
"include": [
"../../apps/web/src/connectors/*.ts",
"../../apps/web/src/models/*.ts",
"../../apps/web/src/services/*.ts",
"../../apps/web/src/abstractions/*.ts"
]
"extends": "../../apps/web/tsconfig"
}

View File

@ -1,34 +1,34 @@
{
"folders": [
{
"name": "root",
"path": "."
},
{
"name": "web vault",
"path": "apps/web"
},
{
"name": "web vault (bit)",
"path": "bitwarden_license/bit-web"
},
{
"name": "cli",
"path": "apps/cli"
},
{
"name": "desktop",
"path": "apps/desktop"
},
{
"name": "browser",
"path": "apps/browser"
},
{
"name": "libs",
"path": "libs"
}
],
"folders": [
{
"name": "root",
"path": "."
},
{
"name": "web vault",
"path": "apps/web"
},
{
"name": "web vault (bit)",
"path": "bitwarden_license/bit-web"
},
{
"name": "cli",
"path": "apps/cli"
},
{
"name": "desktop",
"path": "apps/desktop"
},
{
"name": "browser",
"path": "apps/browser"
},
{
"name": "libs",
"path": "libs"
}
],
"settings": {
"debug.javascript.terminalOptions": {
"sourceMapPathOverrides": {
@ -37,6 +37,20 @@
"webpack://?:*/*": "${workspaceFolder}/*",
"webpack://@bitwarden/cli/*": "${workspaceFolder}/apps/cli/*"
}
}
},
"jest.disabledWorkspaceFolders": [
"root",
"web vault",
"web vault (bit)",
"desktop"
],
"jest.jestCommandLine": "npx jest"
},
"extensions": {
"recommendations": [
"orta.vscode-jest",
"dbaeumer.vscode-eslint",
"esbenp.prettier-vscode"
],
}
}

6
libs/.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,6 @@
{
"eslint.options": {
"ignorePath": "${workspaceFolder}/../../.eslintIgnore"
},
"prettier.ignorePath": "${workspaceFolder}/../../.prettierignore"
}