From b1434c145786cee1f94d1dd7388cf3dae8e9fd0b Mon Sep 17 00:00:00 2001 From: Bertie690 Date: Thu, 7 Aug 2025 11:21:38 -0400 Subject: [PATCH] Removed non-`extensions.json` files; added default config directly to devcontainer --- .devcontainer/devcontainer.json | 40 ++++++++++++++++++- .gitignore | 4 +- .vscode/extensions.json | 8 ++-- .vscode/launch.json | 31 --------------- .vscode/settings.json | 33 ---------------- .vscode/tasks.json | 70 --------------------------------- 6 files changed, 47 insertions(+), 139 deletions(-) delete mode 100644 .vscode/launch.json delete mode 100644 .vscode/settings.json delete mode 100644 .vscode/tasks.json diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index ea72ced5571..e94afd0a9be 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -15,7 +15,45 @@ }, "customizations": { "vscode": { - "extensions": ["aaron-bond.better-comments", ""] + "settings": { + // # Formatter configs + "editor.defaultFormatter": "biomejs.biome", + "editor.tabSize": 2, + "editor.insertSpaces": true, + "editor.codeActionsOnSave": { + "source.addMissingImports.ts": "always", + "source.removeUnusedImports": "always", + "source.fixAll.biome": "always", + "source.organizeImports.biome": "always" + }, + "biome.suggestInstallingGlobally": false, + + // # JS/TS setting overrides + "javascript.preferences.importModuleSpecifier": "non-relative", + "javascript.preferences.importModuleSpecifierEnding": "index", + "javascript.preferGoToSourceDefinition": true, + "javascript.updateImportsOnFileMove.enabled": "always", + + "typescript.preferences.importModuleSpecifier": "non-relative", + "typescript.preferences.importModuleSpecifierEnding": "index", + "typescript.preferGoToSourceDefinition": true, + "typescript.updateImportsOnFileMove.enabled": "always", + + "typescript.tsserver.experimental.enableProjectDiagnostics": true, + + // # Miscellaneous + "npm.packageManager": "pnpm", + "npm.scriptRunner": "pnpm", + "vitest.cliArguments": "--no-isolate" + }, + "extensions": [ + "biomejs.biome", + "YoavBls.pretty-ts-errors", + "vitest.explorer", + "adpyke.codesnap", // Bind to a hotkey (ctrl+\, etc) for best results + "aaron-bond.better-comments", + "MuTsunTsai.jsdoc-link" + ] } }, "postCreateCommand": "pnpm install", diff --git a/.gitignore b/.gitignore index 6ae2ca47371..299767e742a 100644 --- a/.gitignore +++ b/.gitignore @@ -12,8 +12,10 @@ dist dist-ssr *.local -# Editor directories and files +# Editor directories and files (excluding `extensions.json` for devcontainer) *.code-workspace +.vscode/* +!.vscode/extensions.json .idea .DS_Store *.suo diff --git a/.vscode/extensions.json b/.vscode/extensions.json index 4ce39f3c27c..81abc8df2c0 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -4,8 +4,10 @@ "YoavBls.pretty-ts-errors", "vitest.explorer", - // This stuff isn't mandatory - it's just nice to have ;) - "adpyke.codesnap", - "aaron-bond.better-comments" + // This stuff isn't mandatory - it's just nice to have :) + + "adpyke.codesnap", // Bind to a hotkey (ctrl+\, etc) for best results + "aaron-bond.better-comments", + "MuTsunTsai.jsdoc-link" ] } \ No newline at end of file diff --git a/.vscode/launch.json b/.vscode/launch.json deleted file mode 100644 index e53e4256bb9..00000000000 --- a/.vscode/launch.json +++ /dev/null @@ -1,31 +0,0 @@ -{ - // Use IntelliSense to learn about possible attributes. - // Hover to view descriptions of existing attributes. - // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 - "version": "0.2.0", - "configurations": [ - { - "type": "node", - "request": "launch", - "name": "Debug Vitest", - "skipFiles": ["/**"], - "program": "${workspaceFolder}/node_modules/vitest/vitest.mjs", - "args": ["--inspectBrk", "--no-file-parallelism", "${input:testfile}", "-t", "${input:testcase}"], - "autoAttachChildProcesses": true - } - ], - "inputs": [ - { - "id": "testfile", - "type": "promptString", - "description": "Enter test file to run.", - "default": "${fileBasename}" - }, - { - "id": "testcase", - "type": "promptString", - "description": "Enter test case to run.", - "default": "" - } - ] -} \ No newline at end of file diff --git a/.vscode/settings.json b/.vscode/settings.json deleted file mode 100644 index f68c34882d5..00000000000 --- a/.vscode/settings.json +++ /dev/null @@ -1,33 +0,0 @@ -{ - // # Formatter configs - "editor.defaultFormatter": "biomejs.biome", - "editor.tabSize": 2, - "editor.insertSpaces": true, - "editor.codeActionsOnSave": { - "source.addMissingImports.ts": "always", - "source.removeUnusedImports": "always", - "source.fixAll.biome": "always", - "source.organizeImports.biome": "always" - }, - "biome.suggestInstallingGlobally": false, - - // # JS/TS setting overrides - "javascript.preferences.importModuleSpecifier": "non-relative", - "javascript.preferences.importModuleSpecifierEnding": "index", - "javascript.preferGoToSourceDefinition": true, - "javascript.updateImportsOnFileMove.enabled": "always", - - "typescript.preferences.importModuleSpecifier": "non-relative", - "typescript.preferences.importModuleSpecifierEnding": "index", - "typescript.preferGoToSourceDefinition": true, - "typescript.updateImportsOnFileMove.enabled": "always", - - "typescript.tsserver.experimental.enableProjectDiagnostics": true, - // Note: You may want to adjust the max server memory depending on your PC's specs: - // "typescript.tsserver.maxTsServerMemory": 1536, // 1.5 GB by default - - // # Miscellaneous - "npm.packageManager": "pnpm", - "npm.scriptRunner": "pnpm", - "vitest.cliArguments": "--no-isolate", -} diff --git a/.vscode/tasks.json b/.vscode/tasks.json deleted file mode 100644 index ef3d03bb034..00000000000 --- a/.vscode/tasks.json +++ /dev/null @@ -1,70 +0,0 @@ -{ - // See https://go.microsoft.com/fwlink/?LinkId=733558 - // for the documentation about the tasks.json format - "version": "2.0.0", - "presentation": { - "reveal": "never", - "focus": false - }, - "tasks": [ - { - "label": "Update Submodules", - "type": "shell", - "command": "git submodule update --init --recursive", - "icon": { - "color": "terminal.ansiRed", - "id": "git-branch" - }, - }, - { - "label": "Clear Submodules", - "type": "shell", - "command": "rm -rf public/locales; git checkout upstream/beta -- public/locales", - "icon": { - "color": "terminal.ansiRed", - "id": "trash" - }, - }, - { - "label": "Biome - Write All", - "type": "shell", - "command": { - "value": "pnpm", - "quoting": "weak" - }, - "args": [ - "run", - "biome", - "--diagnostic-level=${input:error-level}" - ], - "icon": { - "color": "terminal.ansiBlue", - "id": "json" - }, - "problemMatcher": [] - }, - { - "label": "Start Local Dev", - "type": "npm", - "script": "start:dev", - "icon": { - "color": "terminal.ansiGreen", - "id": "debug-start" - }, - "problemMatcher": [] - } - ], - "inputs": [ - { - "id": "error-level", - "description": "Select the level of errors to report from Biome.", - "type": "pickString", - "options": [ - "error", - "warning", - "info" - ], - "default": "error" - } - ] -} \ No newline at end of file