@the-bearded-bear/claude-craft 8.11.0 → 8.12.0-next.d70c2ba
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Dev/i18n/base/Angular/rules/03-coding-standards.md +57 -1
- package/Dev/i18n/base/CSharp/rules/06-tooling.md +20 -20
- package/Dev/i18n/base/CSharp/rules/08-quality-tools.md +2 -2
- package/Dev/i18n/base/Laravel/rules/06-tooling.md +4 -4
- package/Dev/i18n/base/PHP/checklists/new-feature.md +1 -1
- package/Dev/i18n/base/PHP/checklists/pre-commit.md +2 -2
- package/Dev/i18n/base/PHP/commands/check-code-quality.md +4 -4
- package/Dev/i18n/base/PHP/commands/check-security.md +1 -1
- package/Dev/i18n/base/VueJS/rules/06-tooling.md +36 -5
- package/Dev/i18n/base/VueJS/rules/08-quality-tools.md +2 -0
- package/Dev/i18n/de/Common/commands/setup-rtk.md +118 -47
- package/Dev/i18n/de/Common/rules/11-security.md +2 -1
- package/Dev/i18n/de/Common/rules/12-context-management.md +65 -13
- package/Dev/i18n/de/Common/templates/settings.json.template +6 -5
- package/Dev/i18n/de/Flutter/rules/06-tooling.md +83 -12
- package/Dev/i18n/de/PHP/CLAUDE.md.template +1 -1
- package/Dev/i18n/de/PHP/agents/php-reviewer.md +6 -6
- package/Dev/i18n/de/PHP/commands/check-compliance.md +2 -2
- package/Dev/i18n/de/PHP/rules/06-tooling.md +5 -5
- package/Dev/i18n/de/PHP/rules/08-quality-tools.md +7 -7
- package/Dev/i18n/de/Python/rules/06-tooling.md +5 -2
- package/Dev/i18n/de/Python/rules/08-quality-tools.md +6 -4
- package/Dev/i18n/de/React/rules/03-coding-standards.md +3 -1
- package/Dev/i18n/de/React/rules/06-tooling.md +2 -2
- package/Dev/i18n/de/React/rules/07-testing-react.md +3 -1
- package/Dev/i18n/de/React/rules/08-quality-tools.md +5 -3
- package/Dev/i18n/de/ReactNative/agents/reactnative-reviewer.md +4 -4
- package/Dev/i18n/de/ReactNative/rules/06-tooling.md +31 -9
- package/Dev/i18n/de/Symfony/rules/03-coding-standards.md +3 -1
- package/Dev/i18n/de/UIUX/commands/generate-design-md.md +135 -0
- package/Dev/i18n/en/Common/commands/setup-rtk.md +112 -62
- package/Dev/i18n/en/Common/rules/11-security.md +2 -1
- package/Dev/i18n/en/Common/rules/12-context-management.md +59 -7
- package/Dev/i18n/en/Common/templates/settings.json.template +5 -4
- package/Dev/i18n/en/Flutter/rules/06-tooling.md +82 -11
- package/Dev/i18n/en/PHP/CLAUDE.md.template +2 -2
- package/Dev/i18n/en/PHP/agents/php-reviewer.md +6 -6
- package/Dev/i18n/en/PHP/commands/check-compliance.md +1 -1
- package/Dev/i18n/en/PHP/rules/06-tooling.md +5 -5
- package/Dev/i18n/en/PHP/rules/08-quality-tools.md +7 -7
- package/Dev/i18n/en/Python/rules/06-tooling.md +5 -2
- package/Dev/i18n/en/Python/rules/08-quality-tools.md +5 -3
- package/Dev/i18n/en/React/rules/03-coding-standards.md +3 -1
- package/Dev/i18n/en/React/rules/06-tooling.md +2 -2
- package/Dev/i18n/en/React/rules/07-testing-react.md +3 -1
- package/Dev/i18n/en/React/rules/08-quality-tools.md +5 -3
- package/Dev/i18n/en/ReactNative/agents/reactnative-reviewer.md +4 -4
- package/Dev/i18n/en/ReactNative/rules/06-tooling.md +29 -7
- package/Dev/i18n/en/Symfony/CLAUDE.md.template +1 -1
- package/Dev/i18n/en/Symfony/checklists/README.md +2 -2
- package/Dev/i18n/en/Symfony/commands/check-compliance.md +1 -1
- package/Dev/i18n/en/Symfony/rules/03-coding-standards.md +3 -1
- package/Dev/i18n/en/UIUX/commands/generate-design-md.md +135 -0
- package/Dev/i18n/es/Common/commands/setup-rtk.md +118 -47
- package/Dev/i18n/es/Common/rules/11-security.md +2 -1
- package/Dev/i18n/es/Common/rules/12-context-management.md +71 -19
- package/Dev/i18n/es/Common/templates/settings.json.template +6 -5
- package/Dev/i18n/es/Flutter/rules/06-tooling.md +83 -12
- package/Dev/i18n/es/PHP/CLAUDE.md.template +1 -1
- package/Dev/i18n/es/PHP/agents/php-reviewer.md +6 -6
- package/Dev/i18n/es/PHP/commands/check-compliance.md +2 -2
- package/Dev/i18n/es/PHP/rules/06-tooling.md +5 -5
- package/Dev/i18n/es/PHP/rules/08-quality-tools.md +7 -7
- package/Dev/i18n/es/Python/rules/06-tooling.md +5 -2
- package/Dev/i18n/es/Python/rules/08-quality-tools.md +7 -5
- package/Dev/i18n/es/React/rules/03-coding-standards.md +3 -1
- package/Dev/i18n/es/React/rules/06-tooling.md +2 -2
- package/Dev/i18n/es/React/rules/07-testing-react.md +3 -1
- package/Dev/i18n/es/React/rules/08-quality-tools.md +5 -3
- package/Dev/i18n/es/ReactNative/agents/reactnative-reviewer.md +4 -4
- package/Dev/i18n/es/ReactNative/rules/06-tooling.md +31 -9
- package/Dev/i18n/es/Symfony/rules/03-coding-standards.md +3 -1
- package/Dev/i18n/es/UIUX/commands/generate-design-md.md +135 -0
- package/Dev/i18n/fr/Common/commands/setup-rtk.md +113 -58
- package/Dev/i18n/fr/Common/rules/11-security.md +2 -1
- package/Dev/i18n/fr/Common/rules/12-context-management.md +39 -17
- package/Dev/i18n/fr/Common/templates/settings.json.template +6 -5
- package/Dev/i18n/fr/Flutter/rules/06-tooling.md +71 -0
- package/Dev/i18n/fr/PHP/CLAUDE.md.template +1 -1
- package/Dev/i18n/fr/PHP/agents/php-reviewer.md +6 -6
- package/Dev/i18n/fr/PHP/commands/check-compliance.md +2 -2
- package/Dev/i18n/fr/PHP/rules/06-tooling.md +5 -5
- package/Dev/i18n/fr/PHP/rules/08-quality-tools.md +7 -7
- package/Dev/i18n/fr/Python/rules/06-tooling.md +20 -17
- package/Dev/i18n/fr/Python/rules/08-quality-tools.md +6 -4
- package/Dev/i18n/fr/React/rules/03-coding-standards.md +3 -1
- package/Dev/i18n/fr/React/rules/06-tooling.md +2 -2
- package/Dev/i18n/fr/React/rules/07-testing-react.md +3 -1
- package/Dev/i18n/fr/React/rules/08-quality-tools.md +5 -3
- package/Dev/i18n/fr/ReactNative/agents/reactnative-reviewer.md +4 -4
- package/Dev/i18n/fr/ReactNative/rules/06-tooling.md +31 -9
- package/Dev/i18n/fr/Symfony/rules/03-coding-standards.md +5 -3
- package/Dev/i18n/fr/UIUX/commands/generate-design-md.md +135 -0
- package/Dev/i18n/pt/Common/commands/setup-rtk.md +118 -47
- package/Dev/i18n/pt/Common/rules/11-security.md +2 -1
- package/Dev/i18n/pt/Common/rules/12-context-management.md +74 -22
- package/Dev/i18n/pt/Common/templates/settings.json.template +6 -5
- package/Dev/i18n/pt/Flutter/rules/06-tooling.md +71 -0
- package/Dev/i18n/pt/PHP/CLAUDE.md.template +1 -1
- package/Dev/i18n/pt/PHP/agents/php-reviewer.md +6 -6
- package/Dev/i18n/pt/PHP/commands/check-compliance.md +2 -2
- package/Dev/i18n/pt/PHP/rules/06-tooling.md +5 -5
- package/Dev/i18n/pt/PHP/rules/08-quality-tools.md +7 -7
- package/Dev/i18n/pt/Python/rules/06-tooling.md +5 -2
- package/Dev/i18n/pt/Python/rules/08-quality-tools.md +7 -5
- package/Dev/i18n/pt/React/rules/03-coding-standards.md +3 -1
- package/Dev/i18n/pt/React/rules/06-tooling.md +2 -2
- package/Dev/i18n/pt/React/rules/07-testing-react.md +4 -2
- package/Dev/i18n/pt/React/rules/08-quality-tools.md +5 -3
- package/Dev/i18n/pt/ReactNative/agents/reactnative-reviewer.md +4 -4
- package/Dev/i18n/pt/ReactNative/rules/06-tooling.md +31 -9
- package/Dev/i18n/pt/Symfony/checklists/README.md +2 -2
- package/Dev/i18n/pt/Symfony/rules/03-coding-standards.md +9 -7
- package/Dev/i18n/pt/UIUX/commands/generate-design-md.md +135 -0
- package/README.md +25 -22
- package/Tools/StatusLine/README.md +1 -1
- package/bundles/cursor/.cursorrules +5 -5
- package/bundles/windsurf/.windsurfrules +5 -5
- package/cli/index.js +7 -1
- package/cli/kanban/client/dist/assets/{BurndownView-CX_G3va0.js → BurndownView-BtHuPLAn.js} +1 -1
- package/cli/kanban/client/dist/assets/{DepsView-ihavQy0E.js → DepsView-aDi3K8g1.js} +1 -1
- package/cli/kanban/client/dist/assets/{DocsView-B_ZGSOFP.js → DocsView-BSBVgRt4.js} +1 -1
- package/cli/kanban/client/dist/assets/index-1-77_4RL.css +1 -0
- package/cli/kanban/client/dist/assets/{index-BsBEjSWn.js → index-BbeBQ7DM.js} +2 -2
- package/cli/kanban/client/dist/index.html +2 -2
- package/cli/kanban/client/src/views/KanbanView.svelte +20 -6
- package/cli/kanban/server/app.js +18 -4
- package/cli/kanban/server/middleware/security.js +9 -1
- package/cli/lib/constants.js +4 -5
- package/cli/lib/detect-project.js +121 -90
- package/cli/lib/doctor.js +23 -2
- package/cli/lib/flattener.js +20 -29
- package/cli/lib/install-from-url.js +3 -2
- package/cli/lib/installer.js +8 -0
- package/cli/lib/tech-registry.js +4 -4
- package/package.json +4 -4
- package/cli/kanban/client/dist/assets/index-Bfa1Brzb.css +0 -1
|
@@ -627,6 +627,62 @@ export class SearchComponent {
|
|
|
627
627
|
}
|
|
628
628
|
```
|
|
629
629
|
|
|
630
|
+
## Angular 22 — New Features
|
|
631
|
+
|
|
632
|
+
### @Service decorator (v22)
|
|
633
|
+
|
|
634
|
+
Angular 22 introduces the `@Service` decorator as an ergonomic alias for `@Injectable({ providedIn: 'root' })`:
|
|
635
|
+
|
|
636
|
+
```typescript
|
|
637
|
+
import { Service } from '@angular/core';
|
|
638
|
+
|
|
639
|
+
// Angular 22 — equivalent to @Injectable({ providedIn: 'root' })
|
|
640
|
+
@Service()
|
|
641
|
+
export class UserService {
|
|
642
|
+
getUsers() { /* ... */ }
|
|
643
|
+
}
|
|
644
|
+
```
|
|
645
|
+
|
|
646
|
+
**Compatibility:** `@Injectable` continues to work. `@Service` is the recommended shorthand for root-scoped services.
|
|
647
|
+
|
|
648
|
+
### injectAsync() (v22)
|
|
649
|
+
|
|
650
|
+
`injectAsync()` allows injecting asynchronous dependencies (lazy-loaded, promise-based) directly in the constructor:
|
|
651
|
+
|
|
652
|
+
```typescript
|
|
653
|
+
import { Component, inject, injectAsync } from '@angular/core';
|
|
654
|
+
|
|
655
|
+
@Component({ /* ... */ })
|
|
656
|
+
export class DashboardComponent {
|
|
657
|
+
// injectAsync: lazy resolution of a service or async token
|
|
658
|
+
private analytics = injectAsync(() =>
|
|
659
|
+
import('./analytics.service').then(m => inject(m.AnalyticsService))
|
|
660
|
+
);
|
|
661
|
+
}
|
|
662
|
+
```
|
|
663
|
+
|
|
664
|
+
**Use case:** sharing singletons from micro-frontends or dynamically loaded modules without circular dependency.
|
|
665
|
+
|
|
666
|
+
### Angular Aria (v22)
|
|
667
|
+
|
|
668
|
+
The `@angular/cdk` package (stable in v22) provides accessible primitives: `cdkAriaLive`, `cdkTrapFocus`, `cdkVisuallyHidden`, and new directives `cdkCombobox`, `cdkListbox`:
|
|
669
|
+
|
|
670
|
+
```typescript
|
|
671
|
+
import { CdkListbox, CdkOption } from '@angular/cdk/listbox';
|
|
672
|
+
|
|
673
|
+
@Component({
|
|
674
|
+
standalone: true,
|
|
675
|
+
imports: [CdkListbox, CdkOption],
|
|
676
|
+
template: `
|
|
677
|
+
<ul cdkListbox>
|
|
678
|
+
<li cdkOption="option1">Option 1</li>
|
|
679
|
+
<li cdkOption="option2">Option 2</li>
|
|
680
|
+
</ul>
|
|
681
|
+
`
|
|
682
|
+
})
|
|
683
|
+
export class AccessibleListComponent {}
|
|
684
|
+
```
|
|
685
|
+
|
|
630
686
|
## Conclusion
|
|
631
687
|
|
|
632
688
|
Angular coding standards ensure:
|
|
@@ -635,6 +691,6 @@ Angular coding standards ensure:
|
|
|
635
691
|
2. **Maintainability**: Easy to understand and modify
|
|
636
692
|
3. **Performance**: OnPush, signals, lazy loading
|
|
637
693
|
4. **Type Safety**: Strict TypeScript, typed forms
|
|
638
|
-
5. **Modern Practices**: Standalone components, signals, new control flow
|
|
694
|
+
5. **Modern Practices**: Standalone components, signals, new control flow, @Service decorator
|
|
639
695
|
|
|
640
696
|
**Golden rule**: Write code that is easy to read, test, and maintain.
|
|
@@ -56,13 +56,13 @@ dotnet publish -c Release --self-contained -r linux-x64
|
|
|
56
56
|
|
|
57
57
|
<!-- Entity Framework Core -->
|
|
58
58
|
<ItemGroup>
|
|
59
|
-
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="
|
|
60
|
-
<PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="
|
|
61
|
-
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="
|
|
59
|
+
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="10.*" />
|
|
60
|
+
<PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="10.*" />
|
|
61
|
+
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="10.*">
|
|
62
62
|
<PrivateAssets>all</PrivateAssets>
|
|
63
63
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
|
|
64
64
|
</PackageReference>
|
|
65
|
-
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="
|
|
65
|
+
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="10.*" />
|
|
66
66
|
</ItemGroup>
|
|
67
67
|
|
|
68
68
|
<!-- Testing -->
|
|
@@ -80,13 +80,13 @@ dotnet publish -c Release --self-contained -r linux-x64
|
|
|
80
80
|
<!-- API Documentation -->
|
|
81
81
|
<ItemGroup>
|
|
82
82
|
<PackageReference Include="Swashbuckle.AspNetCore" Version="6.*" />
|
|
83
|
-
<PackageReference Include="Microsoft.AspNetCore.OpenApi" Version="
|
|
83
|
+
<PackageReference Include="Microsoft.AspNetCore.OpenApi" Version="10.*" />
|
|
84
84
|
</ItemGroup>
|
|
85
85
|
|
|
86
86
|
<!-- Resilience & Observability -->
|
|
87
87
|
<ItemGroup>
|
|
88
88
|
<PackageReference Include="Polly" Version="8.*" />
|
|
89
|
-
<PackageReference Include="Serilog.AspNetCore" Version="
|
|
89
|
+
<PackageReference Include="Serilog.AspNetCore" Version="10.*" />
|
|
90
90
|
<PackageReference Include="OpenTelemetry.Extensions.Hosting" Version="1.*" />
|
|
91
91
|
<PackageReference Include="OpenTelemetry.Instrumentation.AspNetCore" Version="1.*" />
|
|
92
92
|
</ItemGroup>
|
|
@@ -171,7 +171,7 @@ trim_trailing_whitespace = false
|
|
|
171
171
|
<!-- Place at solution root for shared project settings -->
|
|
172
172
|
<Project>
|
|
173
173
|
<PropertyGroup>
|
|
174
|
-
<TargetFramework>
|
|
174
|
+
<TargetFramework>net10.0</TargetFramework>
|
|
175
175
|
<ImplicitUsings>enable</ImplicitUsings>
|
|
176
176
|
<Nullable>enable</Nullable>
|
|
177
177
|
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
|
|
@@ -193,14 +193,14 @@ trim_trailing_whitespace = false
|
|
|
193
193
|
|
|
194
194
|
<!-- Code analysis -->
|
|
195
195
|
<ItemGroup>
|
|
196
|
-
<PackageReference Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="
|
|
196
|
+
<PackageReference Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="10.*">
|
|
197
197
|
<PrivateAssets>all</PrivateAssets>
|
|
198
198
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
|
|
199
199
|
</PackageReference>
|
|
200
200
|
<PackageReference Include="StyleCop.Analyzers" Version="1.2.*">
|
|
201
201
|
<PrivateAssets>all</PrivateAssets>
|
|
202
202
|
</PackageReference>
|
|
203
|
-
<PackageReference Include="SonarAnalyzer.CSharp" Version="
|
|
203
|
+
<PackageReference Include="SonarAnalyzer.CSharp" Version="10.*">
|
|
204
204
|
<PrivateAssets>all</PrivateAssets>
|
|
205
205
|
</PackageReference>
|
|
206
206
|
</ItemGroup>
|
|
@@ -217,14 +217,14 @@ trim_trailing_whitespace = false
|
|
|
217
217
|
</PropertyGroup>
|
|
218
218
|
|
|
219
219
|
<ItemGroup>
|
|
220
|
-
<!-- ASP.NET Core -->
|
|
221
|
-
<PackageVersion Include="Microsoft.AspNetCore.OpenApi" Version="
|
|
220
|
+
<!-- ASP.NET Core (.NET 10 LTS — 10.0.9 latest patch) -->
|
|
221
|
+
<PackageVersion Include="Microsoft.AspNetCore.OpenApi" Version="10.0.9" />
|
|
222
222
|
|
|
223
|
-
<!-- Entity Framework Core -->
|
|
224
|
-
<PackageVersion Include="Microsoft.EntityFrameworkCore" Version="
|
|
225
|
-
<PackageVersion Include="Microsoft.EntityFrameworkCore.SqlServer" Version="
|
|
226
|
-
<PackageVersion Include="Microsoft.EntityFrameworkCore.Tools" Version="
|
|
227
|
-
<PackageVersion Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="
|
|
223
|
+
<!-- Entity Framework Core (10.0.9 — aligned with .NET 10 LTS patch cycle) -->
|
|
224
|
+
<PackageVersion Include="Microsoft.EntityFrameworkCore" Version="10.0.9" />
|
|
225
|
+
<PackageVersion Include="Microsoft.EntityFrameworkCore.SqlServer" Version="10.0.9" />
|
|
226
|
+
<PackageVersion Include="Microsoft.EntityFrameworkCore.Tools" Version="10.0.9" />
|
|
227
|
+
<PackageVersion Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="10.0.9" />
|
|
228
228
|
|
|
229
229
|
<!-- Application Layer -->
|
|
230
230
|
<PackageVersion Include="MediatR" Version="12.4.0" />
|
|
@@ -244,13 +244,13 @@ trim_trailing_whitespace = false
|
|
|
244
244
|
<PackageVersion Include="coverlet.collector" Version="6.0.2" />
|
|
245
245
|
|
|
246
246
|
<!-- Observability -->
|
|
247
|
-
<PackageVersion Include="Serilog.AspNetCore" Version="
|
|
247
|
+
<PackageVersion Include="Serilog.AspNetCore" Version="10.0.0" />
|
|
248
248
|
<PackageVersion Include="Polly" Version="8.3.1" />
|
|
249
249
|
|
|
250
250
|
<!-- Analyzers -->
|
|
251
|
-
<PackageVersion Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="
|
|
251
|
+
<PackageVersion Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="10.0.0" />
|
|
252
252
|
<PackageVersion Include="StyleCop.Analyzers" Version="1.2.0-beta.556" />
|
|
253
|
-
<PackageVersion Include="SonarAnalyzer.CSharp" Version="
|
|
253
|
+
<PackageVersion Include="SonarAnalyzer.CSharp" Version="10.27.0.0" />
|
|
254
254
|
</ItemGroup>
|
|
255
255
|
</Project>
|
|
256
256
|
```
|
|
@@ -459,7 +459,7 @@ jobs:
|
|
|
459
459
|
"type": "coreclr",
|
|
460
460
|
"request": "launch",
|
|
461
461
|
"preLaunchTask": "build",
|
|
462
|
-
"program": "${workspaceFolder}/src/WebAPI/bin/Debug/
|
|
462
|
+
"program": "${workspaceFolder}/src/WebAPI/bin/Debug/net10.0/WebAPI.dll",
|
|
463
463
|
"args": [],
|
|
464
464
|
"cwd": "${workspaceFolder}/src/WebAPI",
|
|
465
465
|
"stopAtEntry": false,
|
|
@@ -64,8 +64,8 @@
|
|
|
64
64
|
### SonarAnalyzer
|
|
65
65
|
|
|
66
66
|
```xml
|
|
67
|
-
<!-- Security and code quality -->
|
|
68
|
-
<PackageReference Include="SonarAnalyzer.CSharp" Version="
|
|
67
|
+
<!-- Security and code quality — SonarAnalyzer 10.27 (412 new rules, C# 14) -->
|
|
68
|
+
<PackageReference Include="SonarAnalyzer.CSharp" Version="10.*">
|
|
69
69
|
<PrivateAssets>all</PrivateAssets>
|
|
70
70
|
</PackageReference>
|
|
71
71
|
```
|
|
@@ -251,10 +251,10 @@ return RectorConfig::configure()
|
|
|
251
251
|
"larastan/larastan": "^2.9",
|
|
252
252
|
"mockery/mockery": "^1.6",
|
|
253
253
|
"nunomaduro/collision": "^8.0",
|
|
254
|
-
"pestphp/pest": "^
|
|
255
|
-
"pestphp/pest-plugin-laravel": "^
|
|
256
|
-
"phpstan/phpstan": "^
|
|
257
|
-
"rector/rector": "^
|
|
254
|
+
"pestphp/pest": "^4.7",
|
|
255
|
+
"pestphp/pest-plugin-laravel": "^4.0",
|
|
256
|
+
"phpstan/phpstan": "^2.2",
|
|
257
|
+
"rector/rector": "^2.4",
|
|
258
258
|
"spatie/laravel-ignition": "^2.4"
|
|
259
259
|
}
|
|
260
260
|
}
|
|
@@ -58,7 +58,7 @@ grumphp:
|
|
|
58
58
|
diff: true
|
|
59
59
|
phpstan:
|
|
60
60
|
configuration: phpstan.neon
|
|
61
|
-
level:
|
|
61
|
+
level: 10
|
|
62
62
|
phpunit:
|
|
63
63
|
testsuite: Unit
|
|
64
64
|
always_execute: true
|
|
@@ -93,7 +93,7 @@ vendor/bin/php-cs-fixer fix # Fix code style
|
|
|
93
93
|
vendor/bin/rector process # Apply refactorings
|
|
94
94
|
|
|
95
95
|
# Static analysis
|
|
96
|
-
vendor/bin/phpstan analyse # PHPStan level
|
|
96
|
+
vendor/bin/phpstan analyse # PHPStan level 10
|
|
97
97
|
vendor/bin/psalm # Psalm analysis
|
|
98
98
|
|
|
99
99
|
# Tests
|
|
@@ -9,7 +9,7 @@ Run comprehensive code quality analysis on PHP project.
|
|
|
9
9
|
## What This Command Does
|
|
10
10
|
|
|
11
11
|
1. **Static Analysis**
|
|
12
|
-
- PHPStan level
|
|
12
|
+
- PHPStan level 10 analysis
|
|
13
13
|
- Psalm strict mode check
|
|
14
14
|
- Type coverage verification
|
|
15
15
|
- Dead code detection
|
|
@@ -50,7 +50,7 @@ includes:
|
|
|
50
50
|
|
|
51
51
|
parameters:
|
|
52
52
|
phpVersion: 80400
|
|
53
|
-
level:
|
|
53
|
+
level: 10
|
|
54
54
|
|
|
55
55
|
paths:
|
|
56
56
|
- src
|
|
@@ -374,7 +374,7 @@ final class UserRepository implements RepositoryInterface
|
|
|
374
374
|
## Quality Gate Checklist
|
|
375
375
|
|
|
376
376
|
### Static Analysis
|
|
377
|
-
- [ ] PHPStan level
|
|
377
|
+
- [ ] PHPStan level 10 passes
|
|
378
378
|
- [ ] No Psalm errors at level 1
|
|
379
379
|
- [ ] No type errors
|
|
380
380
|
- [ ] No dead code detected
|
|
@@ -436,7 +436,7 @@ quality:
|
|
|
436
436
|
- name: Setup PHP
|
|
437
437
|
uses: shivammathur/setup-php@v2
|
|
438
438
|
with:
|
|
439
|
-
php-version: '8.
|
|
439
|
+
php-version: '8.5'
|
|
440
440
|
|
|
441
441
|
- name: Install dependencies
|
|
442
442
|
run: composer install
|
|
@@ -38,6 +38,8 @@ export default defineConfig({
|
|
|
38
38
|
sourcemap: true,
|
|
39
39
|
rollupOptions: {
|
|
40
40
|
output: {
|
|
41
|
+
// ⚠️ Vite 8 (Rolldown): manualChunks is deprecated when Rolldown is active (default bundler in Vite 8).
|
|
42
|
+
// Remove or condition to `build.rolldown !== true`. Rolldown produces equivalent or better automatic chunking.
|
|
41
43
|
manualChunks: {
|
|
42
44
|
'vue-vendor': ['vue', 'vue-router', 'pinia'],
|
|
43
45
|
},
|
|
@@ -71,7 +73,7 @@ const isProd = import.meta.env.PROD
|
|
|
71
73
|
### Configuration
|
|
72
74
|
|
|
73
75
|
```javascript
|
|
74
|
-
// eslint.config.js (Flat config - ESLint
|
|
76
|
+
// eslint.config.js (Flat config - ESLint v9+/v10; .eslintrc.* removed in v10)
|
|
75
77
|
import js from '@eslint/js'
|
|
76
78
|
import vue from 'eslint-plugin-vue'
|
|
77
79
|
import typescript from '@typescript-eslint/eslint-plugin'
|
|
@@ -285,6 +287,35 @@ pnpm build
|
|
|
285
287
|
pnpm test
|
|
286
288
|
```
|
|
287
289
|
|
|
290
|
+
## Vue Router 5 — File-Based Routing (optional)
|
|
291
|
+
|
|
292
|
+
Vue Router 5 introduces optional **file-based routing** via `@vue-router/auto` (based on unplugin-vue-router):
|
|
293
|
+
|
|
294
|
+
```bash
|
|
295
|
+
npm install -D @vue-router/auto unplugin-vue-router
|
|
296
|
+
```
|
|
297
|
+
|
|
298
|
+
```typescript
|
|
299
|
+
// vite.config.ts
|
|
300
|
+
import VueRouter from 'unplugin-vue-router/vite';
|
|
301
|
+
|
|
302
|
+
export default defineConfig({
|
|
303
|
+
plugins: [
|
|
304
|
+
VueRouter({ /* options */ }),
|
|
305
|
+
Vue(),
|
|
306
|
+
],
|
|
307
|
+
});
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
```typescript
|
|
311
|
+
// src/main.ts — use auto-generated router
|
|
312
|
+
import { createRouter, createWebHistory } from 'vue-router/auto';
|
|
313
|
+
|
|
314
|
+
const router = createRouter({ history: createWebHistory() });
|
|
315
|
+
```
|
|
316
|
+
|
|
317
|
+
> Files in `src/pages/` are automatically mapped to routes. `createRouter` from `vue-router/auto` replaces the manual route array.
|
|
318
|
+
|
|
288
319
|
## Project Scripts
|
|
289
320
|
|
|
290
321
|
### Recommended package.json
|
|
@@ -305,8 +336,8 @@ pnpm test
|
|
|
305
336
|
"test:coverage": "vitest --coverage",
|
|
306
337
|
"test:e2e": "playwright test",
|
|
307
338
|
"type-check": "vue-tsc --noEmit -p tsconfig.json --composite false",
|
|
308
|
-
"lint": "eslint .
|
|
309
|
-
"lint:fix": "eslint . --
|
|
339
|
+
"lint": "eslint .",
|
|
340
|
+
"lint:fix": "eslint . --fix",
|
|
310
341
|
"format": "prettier --write src/",
|
|
311
342
|
"format:check": "prettier --check src/",
|
|
312
343
|
"prepare": "husky install"
|
|
@@ -320,12 +351,12 @@ pnpm test
|
|
|
320
351
|
"@types/node": "^20.0.0",
|
|
321
352
|
"@vitejs/plugin-vue": "^6.0.0",
|
|
322
353
|
"@vue/test-utils": "^2.4.0",
|
|
323
|
-
"eslint": "^
|
|
354
|
+
"eslint": "^10.0.0",
|
|
324
355
|
"eslint-plugin-vue": "^10.0.0",
|
|
325
356
|
"prettier": "^3.0.0",
|
|
326
357
|
"typescript": "~5.4.0",
|
|
327
358
|
"vite": "^8.0.0",
|
|
328
|
-
"vitest": "^
|
|
359
|
+
"vitest": "^4.0.0",
|
|
329
360
|
"vue-tsc": "^2.0.0"
|
|
330
361
|
}
|
|
331
362
|
}
|
|
@@ -335,6 +335,8 @@ export default defineConfig({
|
|
|
335
335
|
build: {
|
|
336
336
|
rollupOptions: {
|
|
337
337
|
output: {
|
|
338
|
+
// ⚠️ Vite 8 (Rolldown): manualChunks is deprecated when Rolldown is the active bundler.
|
|
339
|
+
// Remove or condition to build.rolldown !== true for Vite 8+ projects.
|
|
338
340
|
manualChunks: {
|
|
339
341
|
'vue-vendor': ['vue', 'vue-router', 'pinia'],
|
|
340
342
|
'ui-vendor': ['@headlessui/vue', '@heroicons/vue'],
|
|
@@ -1,78 +1,149 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: RTK
|
|
3
|
-
argument-hint: [--
|
|
2
|
+
description: RTK und Token-Optimierung für Claude Code konfigurieren
|
|
3
|
+
argument-hint: [--check]
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
#
|
|
6
|
+
# Token-Optimierung einrichten
|
|
7
7
|
|
|
8
|
-
RTK
|
|
8
|
+
RTK (Rust Token Killer) und umfassende Token-Optimierung für Claude Code-Sitzungen konfigurieren.
|
|
9
9
|
|
|
10
|
-
##
|
|
10
|
+
## Schritte
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
## Ausfuehrung
|
|
15
|
-
|
|
16
|
-
### Phase 1: Voraussetzungen pruefen
|
|
17
|
-
|
|
18
|
-
Verfuegbarkeit der erforderlichen Tools ueberpruefen:
|
|
12
|
+
### 1. RTK-Installation prüfen
|
|
19
13
|
|
|
14
|
+
```bash
|
|
15
|
+
# Prüfen ob RTK installiert ist
|
|
16
|
+
if command -v rtk &>/dev/null; then
|
|
17
|
+
echo "RTK installiert: $(rtk --version)"
|
|
18
|
+
echo ""
|
|
19
|
+
rtk gain 2>/dev/null || echo "Noch keine Einsparungsdaten"
|
|
20
|
+
else
|
|
21
|
+
echo "RTK ist NICHT installiert"
|
|
22
|
+
echo ""
|
|
23
|
+
echo "Installationsoptionen (das curl|bash-Muster ist durch Claude Craft Hooks BLOCKIERT):"
|
|
24
|
+
echo " 1. (Empfohlen) make install-rtk # aus dem claude-craft Root"
|
|
25
|
+
echo " 2. cargo install rtk-cli # wenn Rust Toolchain vorhanden"
|
|
26
|
+
echo " 3. Release-Binary manuell herunterladen: https://github.com/rtk-ai/rtk/releases"
|
|
27
|
+
fi
|
|
20
28
|
```
|
|
21
|
-
╔══════════════════════════════════════════════════════════════╗
|
|
22
|
-
║ RTK - Token-Optimierer Einrichtung ║
|
|
23
|
-
╚══════════════════════════════════════════════════════════════╝
|
|
24
29
|
|
|
25
|
-
|
|
26
|
-
✓ jq installiert
|
|
27
|
-
✓ curl installiert
|
|
28
|
-
```
|
|
30
|
+
### 2. RTK-Optimierungen konfigurieren
|
|
29
31
|
|
|
30
|
-
|
|
32
|
+
Falls RTK installiert ist, diese Optimierungen anwenden:
|
|
31
33
|
|
|
32
|
-
|
|
34
|
+
#### a) Ultra-Compact-Modus aktivieren
|
|
33
35
|
|
|
34
|
-
|
|
36
|
+
Den Hook unter `~/.claude/hooks/rtk-rewrite.sh` prüfen. Der Rewrite-Befehl sollte `--ultra-compact` verwenden:
|
|
35
37
|
|
|
36
38
|
```bash
|
|
37
|
-
|
|
39
|
+
REWRITTEN=$(rtk rewrite --ultra-compact "$CMD" 2>/dev/null)
|
|
38
40
|
```
|
|
39
41
|
|
|
40
|
-
|
|
42
|
+
Falls nicht vorhanden, die Hook-Datei aktualisieren.
|
|
41
43
|
|
|
42
|
-
|
|
44
|
+
#### b) RTK-Limits optimieren
|
|
43
45
|
|
|
44
|
-
`
|
|
45
|
-
- `~/.claude/hooks/rtk-rewrite.sh` — Das PreToolUse Hook-Skript
|
|
46
|
-
- `~/.claude/RTK.md` — RTK-Konfigurationsreferenz
|
|
46
|
+
`~/.config/rtk/config.toml` prüfen und diese Limits empfehlen:
|
|
47
47
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
48
|
+
```toml
|
|
49
|
+
[limits]
|
|
50
|
+
grep_max_results = 100
|
|
51
|
+
grep_max_per_file = 10
|
|
52
|
+
status_max_files = 10
|
|
53
|
+
status_max_untracked = 5
|
|
54
|
+
passthrough_max_chars = 1500
|
|
55
|
+
```
|
|
53
56
|
|
|
54
|
-
|
|
57
|
+
#### c) Benutzerdefinierte Filter hinzufügen
|
|
55
58
|
|
|
56
|
-
|
|
59
|
+
`~/.config/rtk/filters.toml` prüfen. Wenn nur Template-Kommentare vorhanden sind, Filter basierend auf dem erkannten Projekt-Stack vorschlagen:
|
|
57
60
|
|
|
58
|
-
|
|
61
|
+
- **Docker-Projekte**: docker exec, compose, logs Filter hinzufügen
|
|
62
|
+
- **Node.js-Projekte**: npm/npx install Filter hinzufügen
|
|
63
|
+
- **PHP-Projekte**: composer Filter hinzufügen
|
|
64
|
+
- **Python-Projekte**: pip install Filter hinzufügen
|
|
59
65
|
|
|
60
|
-
|
|
61
|
-
|-------|-----------|
|
|
62
|
-
| `--install` (Standard) | Vollstaendige Installation: Binary + Hooks + Settings-Zusammenfuehrung |
|
|
63
|
-
| `--check` | RTK-Installationsstatus und Einsparungen pruefen |
|
|
64
|
-
| `--uninstall` | RTK-Hooks aus settings.json entfernen (Binary beibehalten) |
|
|
66
|
+
### 3. Sub-Agent-Modell und Forked Subagents konfigurieren
|
|
65
67
|
|
|
66
|
-
|
|
68
|
+
Prüfen ob beide Umgebungsvariablen gesetzt sind:
|
|
67
69
|
|
|
68
70
|
```bash
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
/common:setup-rtk --uninstall
|
|
71
|
+
echo "CLAUDE_CODE_SUBAGENT_MODEL=${CLAUDE_CODE_SUBAGENT_MODEL:-NICHT GESETZT}"
|
|
72
|
+
echo "CLAUDE_CODE_FORK_SUBAGENT=${CLAUDE_CODE_FORK_SUBAGENT:-NICHT GESETZT}"
|
|
72
73
|
```
|
|
73
74
|
|
|
74
|
-
|
|
75
|
+
Falls nicht gesetzt, empfehlen zu `~/.bashrc` (oder `~/.zshrc`) hinzuzufügen:
|
|
75
76
|
|
|
76
77
|
```bash
|
|
77
|
-
|
|
78
|
+
# Sonnet 4.6 für Sub-Agents verwenden (Exploration, grep, Dateilesen) statt Opus
|
|
79
|
+
# → 40-60% Kostenreduzierung bei Sub-Agent-Aufrufen
|
|
80
|
+
export CLAUDE_CODE_SUBAGENT_MODEL="sonnet"
|
|
81
|
+
|
|
82
|
+
# Sub-Agents in isolierten Kontexten ausführen (Claude Code 2.1.117+, siehe COMPATIBILITY.md)
|
|
83
|
+
# → Verhindert Verschmutzung des Hauptkontextfensters durch Sub-Agent-Zwischenzustände
|
|
84
|
+
# → Kombiniert mit context: fork in Skills (~8-15K Token gespart pro langer Sitzung)
|
|
85
|
+
export CLAUDE_CODE_FORK_SUBAGENT=1
|
|
86
|
+
|
|
87
|
+
# 1-Stunden Prompt-Cache TTL aktivieren (Claude Code 2.1.108+)
|
|
88
|
+
# → -40% Kosten bei wiederholenden Sitzungen (BMAD Sprints, /team:* Schleifen)
|
|
89
|
+
# → Gleicher Prompt-Cache-Schlüssel wird bis zu 1h statt 5min Standard wiederverwendet
|
|
90
|
+
export ENABLE_PROMPT_CACHING_1H=1
|
|
91
|
+
|
|
92
|
+
# 5-Minuten Cache-Schreibvorgänge bei jedem Turn erzwingen (Claude Code 2.1.108+)
|
|
93
|
+
# → Nützlich für kurze Entwicklungsschleifen, die den Cache wiederholt treffen
|
|
94
|
+
# → Kompromiss: kleiner Schreib-Overhead, große Hit-Rate-Gewinne bei iterativer Arbeit
|
|
95
|
+
export FORCE_PROMPT_CACHING_5M=1
|
|
78
96
|
```
|
|
97
|
+
|
|
98
|
+
Nach der Aktualisierung Shell neu laden: `source ~/.bashrc`.
|
|
99
|
+
|
|
100
|
+
### 4. Hooks konfigurieren
|
|
101
|
+
|
|
102
|
+
Die aktuellen settings.json auf folgende Hooks prüfen:
|
|
103
|
+
|
|
104
|
+
| Hook | Zweck | Status |
|
|
105
|
+
|------|-------|--------|
|
|
106
|
+
| **PreToolUse** (Bash) | RTK-Rewrite | Konfiguration prüfen |
|
|
107
|
+
| **PostToolUse** (Bash) | Output-Filterung | Konfiguration prüfen |
|
|
108
|
+
| **PreCompact** | Kontext-Erhaltung | Konfiguration prüfen |
|
|
109
|
+
| **SessionStart** (compact) | Kontext-Wiederherstellung | Konfiguration prüfen |
|
|
110
|
+
|
|
111
|
+
Für fehlende Hooks die Templates in `.claude/templates/hooks/` referenzieren:
|
|
112
|
+
- `output-filter.json` — PostToolUse für große Output-Filterung
|
|
113
|
+
- `pre-compact.json` — PreCompact für Kontext-Erhaltung
|
|
114
|
+
- `context-reinject.json` — SessionStart für Post-Compaction-Wiederherstellung
|
|
115
|
+
- `post-compact.json` — PostCompact für Kontext-Wiederherstellung nach Compaction
|
|
116
|
+
|
|
117
|
+
#### PostCompact Hook — Kontext-Wiederherstellung
|
|
118
|
+
|
|
119
|
+
Der **PostCompact**-Hook (Claude Code v2.1.76+) stellt kritischen Kontext nach einem automatischen Compaction-Ereignis wieder her. Ohne ihn kann Claude laufende Aufgaben, Dateipfade und frühere Entscheidungen verlieren.
|
|
120
|
+
|
|
121
|
+
Template: `.claude/templates/hooks/post-compact.json`
|
|
122
|
+
|
|
123
|
+
Der Hook liest `context-essentials.md` (eine Datei mit aktuellem Sitzungszustand) und injiziert sie als System-Nachricht nach der Compaction. Mit dem **PreCompact**-Hook (`pre-compact.json`) kombinieren, der die Essentials vor der Compaction speichert.
|
|
124
|
+
|
|
125
|
+
Geschätzte Einsparung: vermeidet 5-15 Erklärungsrunden pro langer Sitzung (~3-8K Token).
|
|
126
|
+
|
|
127
|
+
### 5. Zusammenfassung
|
|
128
|
+
|
|
129
|
+
Zusammenfassungstabelle aller Optimierungen mit Status anzeigen:
|
|
130
|
+
|
|
131
|
+
| Optimierung | Erwartete Einsparung | Status |
|
|
132
|
+
|---|---|---|
|
|
133
|
+
| RTK installiert + Hooks | 60-90% bei CLI-Output | ? |
|
|
134
|
+
| RTK ultra-compact | +5-10% zusätzlich | ? |
|
|
135
|
+
| RTK optimierte Limits | grep 19% -> 40-50% | ? |
|
|
136
|
+
| RTK benutzerdefinierte Filter | +30-50% bei docker/npm | ? |
|
|
137
|
+
| Sub-Agent-Modell (Sonnet) | 40-60% Kostenreduzierung | ? |
|
|
138
|
+
| Isolierte Sub-Agents (`CLAUDE_CODE_FORK_SUBAGENT=1`) | 8-15K Token/lange Sitzung | ? |
|
|
139
|
+
| Prompt-Caching 1h (`ENABLE_PROMPT_CACHING_1H=1`) | -40% Kosten bei wiederholenden Sitzungen | ? |
|
|
140
|
+
| Cache-Schreibvorgänge 5min erzwingen (`FORCE_PROMPT_CACHING_5M=1`) | Höhere Hit-Rate bei iterativen Schleifen | ? |
|
|
141
|
+
| PostToolUse Hook | Reduziert Kontext-Verschmutzung | ? |
|
|
142
|
+
| PreCompact Hook | Erhält kritischen Kontext | ? |
|
|
143
|
+
| PostCompact Hook | Stellt Kontext nach Compaction wieder her | ? |
|
|
144
|
+
|
|
145
|
+
**Ziel: 60-75% gesamte Token-Effizienz (mit 1h Cache + ultra-compact + forked subagents)**
|
|
146
|
+
|
|
147
|
+
## Argumente
|
|
148
|
+
|
|
149
|
+
- `$ARGUMENTS` — `--check` übergeben, um nur den aktuellen Status anzuzeigen ohne Änderungen vorzunehmen
|
|
@@ -613,6 +613,7 @@ Vor der Installation eines MCP-Servers von Drittanbietern:
|
|
|
613
613
|
### PreToolUse-Hook für Sicherheit
|
|
614
614
|
|
|
615
615
|
> **Best Practice:** Hooks empfangen den Tool-Input als JSON auf **stdin** — immer `jq -r '.tool_input.<feld>'` verwenden (nicht `echo '$TOOL_INPUT'`), um Werte sicher zu lesen und Shell-Injection zu vermeiden.
|
|
616
|
+
> **Wichtig:** `exit 2` verwenden (nicht `exit 1`), um den Tool-Aufruf in Claude Code tatsächlich zu blockieren. `exit 1` signalisiert nur einen Fehler, **blockiert** die Ausführung aber **nicht**.
|
|
616
617
|
|
|
617
618
|
```json
|
|
618
619
|
{
|
|
@@ -623,7 +624,7 @@ Vor der Installation eines MCP-Servers von Drittanbietern:
|
|
|
623
624
|
"hooks": [
|
|
624
625
|
{
|
|
625
626
|
"type": "command",
|
|
626
|
-
"command": "INPUT=$(jq -r '.tool_input.command // empty');
|
|
627
|
+
"command": "INPUT=$(jq -r '.tool_input.command // empty'); printf '%s' \"$INPUT\" | grep -qE '(curl|wget).*\\.(sh|py|rb)' && echo 'BLOCKED: suspicious download' >&2 && exit 2 || exit 0"
|
|
627
628
|
}
|
|
628
629
|
]
|
|
629
630
|
}
|