Skip to content

Commit 7b68552

Browse files
committed
Moved vscode build tasks to the root for better copilot experience with frontend and backend.
1 parent 5d1b1aa commit 7b68552

File tree

10 files changed

+491
-403
lines changed

10 files changed

+491
-403
lines changed

.github/copilot-instructions.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ You are a distinguished engineer and are expected to deliver high-quality code t
1313
- Preserve extra spaces, comments, and minimize diffs.
1414
- Always ask before creating new files, directories, or changing existing structures.
1515
- Always look at existing usages before refactoring or changing code to prevent new code from breaking existing code.
16+
- Assume any existing uncommitted code is correct and ask before changing it.
17+
- Don't add code comments unless necessary. Code should be self-explanatory.
18+
- Don't use deprecated or insecure libraries, algorithms or features.
1619

1720
- **Modern Code Practices:**
1821
- Write complete, runnable code—no placeholders or TODOs.
@@ -32,20 +35,26 @@ Located in the `src/Exceptionless.Web/ClientApp` directory.
3235
- **Framework & Best Practices:**
3336
- Use Svelte 5 in SPA mode with TypeScript and Tailwind CSS.
3437
- Follow modern ES6 best practices and the ESLint recommended configuration ([standardjs](https://standardjs.com)).
35-
- Code can be formatted and linted with `npm run format` and checked for errors with `npm run check`.
38+
- Code can be formatted and linted with `npm run format` and checked for errors with `npm run check` tasks.
39+
- Don't use namespace imports unless importing svelte-shadcn component or from a barrel export index file.
40+
- Limit use of $effect as there is usually a better way to solve the problem like using $derived.
3641

3742
- **Architecture & Components:**
3843
- Follow the Composite Component Pattern.
3944
- Organize code into vertical slices (e.g., features aligned with API controllers) and maintain shared components in a central folder.
4045
- Use **kebab-case** for filenames and directories (e.g., `components/event-overview.svelte`).
4146
- Reexport generated code `src/Exceptionless.Web/ClientApp/src/lib/generated` from the respective feature models folder.
47+
- Always look for models in generated code before creating new models.
48+
- If a function returns a promise always await it.
4249
- **Do NOT** use any server-side Svelte features.
4350

4451
- **UI, Accessibility & Testing:**
4552
- Ensure excellent keyboard navigation for all interactions.
4653
- Build forms with shadcn-svelte forms & superforms, and validate with class-validator.
4754
- Good examples are the manage account and login pages.
4855
- Use formatters `src/Exceptionless.Web/ClientApp/src/lib/features/shared/components/formatters` for displaying built-in types (date, number, boolean, etc.).
56+
- All dialogs should use shadcn-svelte dialog components.
57+
- Good examples are the mark fixed and delete stack dialogs.
4958
- Ensure semantic HTML, mobile-first design, and WCAG 2.2 Level AA compliance.
5059
- Use shadcn-svelte components (based on [bits-ui](https://bits-ui.com/docs/llms.txt)).
5160
- Look for new components in the shadcn-svelte documentation
@@ -62,6 +71,7 @@ Located in the `src/Exceptionless.Web/ClientApp` directory.
6271
- **Reference documentation:**
6372
- Always use Svelte 5 features: [https://svelte.dev/llms-full.txt](https://svelte.dev/llms-full.txt)
6473
- on:click -> onclick
74+
- import { page } from '$app/stores'; -> import { page } from '$app/state';
6575

6676
---
6777

.vscode/extensions.json

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,13 @@
44
"streetsidesoftware.code-spell-checker",
55
"tintoy.msbuild-project-tools",
66
"humao.rest-client",
7-
"ms-kubernetes-tools.vscode-kubernetes-tools"
7+
"ms-kubernetes-tools.vscode-kubernetes-tools",
8+
"svelte.svelte-vscode",
9+
"bradlc.vscode-tailwindcss",
10+
"dbaeumer.vscode-eslint",
11+
"esbenp.prettier-vscode",
12+
"ms-playwright.playwright",
13+
"selemondev.vscode-shadcn-svelte",
14+
"vitest.explorer"
815
]
916
}

.vscode/launch.json

Lines changed: 63 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,68 @@
3838
"name": ".NET Core Attach",
3939
"type": "coreclr",
4040
"request": "attach"
41+
},
42+
{
43+
"name": "frontend: Attach to Chrome",
44+
"port": 9222,
45+
"request": "attach",
46+
"type": "chrome",
47+
"webRoot": "${workspaceFolder}/src/Exceptionless.Web/ClientApp"
48+
},
49+
{
50+
"name": "frontend: Attach to Edge",
51+
"port": 9222,
52+
"request": "attach",
53+
"type": "msedge",
54+
"webRoot": "${workspaceFolder}/src/Exceptionless.Web/ClientApp"
55+
},
56+
{
57+
"type": "msedge",
58+
"request": "launch",
59+
"name": "frontend: Web (Edge)",
60+
"url": "http://localhost:5173/next",
61+
"webRoot": "${workspaceFolder}/src/Exceptionless.Web/ClientApp",
62+
"preLaunchTask": "npm run dev"
63+
},
64+
{
65+
"type": "msedge",
66+
"request": "launch",
67+
"name": "frontend: Web Dev Api (Edge)",
68+
"url": "http://localhost:5173/next",
69+
"webRoot": "${workspaceFolder}/src/Exceptionless.Web/ClientApp",
70+
"preLaunchTask": "npm run dev:api"
71+
},
72+
{
73+
"type": "msedge",
74+
"request": "launch",
75+
"name": "frontend: Storybook (Edge)",
76+
"url": "http://localhost:6006",
77+
"webRoot": "${workspaceFolder}/src/Exceptionless.Web/ClientApp",
78+
"preLaunchTask": "npm run storybook"
79+
},
80+
{
81+
"type": "chrome",
82+
"request": "launch",
83+
"name": "frontend: Web (Chrome)",
84+
"url": "http://localhost:5173/next",
85+
"webRoot": "${workspaceFolder}/src/Exceptionless.Web/ClientApp",
86+
"preLaunchTask": "npm run dev"
87+
},
88+
{
89+
"type": "chrome",
90+
"request": "launch",
91+
"name": "frontend: Web Dev Api (Chrome)",
92+
"url": "http://localhost:5173/next",
93+
"webRoot": "${workspaceFolder}/src/Exceptionless.Web/ClientApp",
94+
"preLaunchTask": "npm run dev:api"
95+
},
96+
{
97+
"type": "chrome",
98+
"request": "launch",
99+
"name": "frontend: Storybook (Chrome)",
100+
"url": "http://localhost:6006",
101+
"webRoot": "${workspaceFolder}/src/Exceptionless.Web/ClientApp",
102+
"preLaunchTask": "npm run storybook"
41103
}
42104
]
43-
}
105+
}

.vscode/settings.json

Lines changed: 80 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,94 @@
44
"**/.git": true,
55
"**/.DS_Store": true,
66
"build/elasticsearch-*": true,
7-
"build/kibana-*": true
7+
"build/kibana-*": true,
8+
"src/Exceptionless.Web/ClientApp/.svelte-kit": true,
9+
"src/Exceptionless.Web/ClientApp/build": true
810
},
911
"dotnet-test-explorer.testProjectPath": "tests/Exceptionless.Tests",
1012
"cSpell.words": [
11-
"Exceptionless",
12-
"Guid",
13-
"LDAP",
14-
"Serilog",
15-
"Xunit",
13+
"acacode",
14+
"autodocs",
1615
"circleci",
16+
"classvalidator",
17+
"clsx",
18+
"cmdk",
19+
"colour",
1720
"dockerignore",
1821
"editorconfig",
1922
"elasticsearch",
20-
"gitignore"
23+
"Exceptionless",
24+
"fetchclient",
25+
"formsnap",
26+
"Foundatio",
27+
"gitignore",
28+
"Guid",
29+
"haserror",
30+
"iconify",
31+
"keyof",
32+
"LDAP",
33+
"legos",
34+
"lucene",
35+
"lucide",
36+
"nameof",
37+
"navigatetofirstpage",
38+
"oidc",
39+
"promotedtabs",
40+
"rowclick",
41+
"runed",
42+
"satellizer",
43+
"Serilog",
44+
"sessionend",
45+
"shadcn",
46+
"sonner",
47+
"standardjs",
48+
"superforms",
49+
"tailwindcss",
50+
"tanstack",
51+
"typeschema",
52+
"WCAG",
53+
"websockets",
54+
"Xunit"
55+
],
56+
"css.customData": [
57+
".vscode/tailwind.json"
2158
],
59+
"css.lint.unknownAtRules": "ignore",
60+
"[javascript]": {
61+
"editor.defaultFormatter": "esbenp.prettier-vscode"
62+
},
63+
"[typescript]": {
64+
"editor.defaultFormatter": "esbenp.prettier-vscode"
65+
},
66+
"[svelte]": {
67+
"editor.defaultFormatter": "svelte.svelte-vscode"
68+
},
69+
"[json]": {
70+
"editor.defaultFormatter": "esbenp.prettier-vscode"
71+
},
72+
"prettier.documentSelectors": [
73+
"**/*.svelte"
74+
],
75+
"editor.codeActionsOnSave": {
76+
"source.fixAll": "explicit"
77+
},
78+
"editor.formatOnSave": true,
79+
"eslint.validate": [
80+
"javascript",
81+
"svelte"
82+
],
83+
"svelte.plugin.svelte.defaultScriptLanguage": "ts",
84+
"tailwindCSS.includeLanguages": {
85+
"svelte": "html"
86+
},
87+
"typescript.tsdk": "\\src\\Exceptionless.Web\\ClientApp\\node_modules\\typescript\\lib",
88+
"workbench.editor.customLabels.patterns": {
89+
"**/lib/**/*.ts": "${dirname}/${filename}.${extname}",
90+
"**/routes/**/+page.svelte": "${dirname(1)}/${dirname}",
91+
"**/routes/**/+layout.svelte": "${dirname}/+layout.svelte",
92+
"**/routes/**/routes.ts": "${dirname}/routes.ts",
93+
"**/lib/**/index.ts": "${dirname}/index.ts"
94+
},
2295
"powershell.codeFormatting.addWhitespaceAroundPipe": true,
2396
"dotnet.defaultSolution": "Exceptionless.sln"
2497
}

0 commit comments

Comments
 (0)