Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions biome-plugins/api-property-record-type.grit
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
// Plugin to detect Record<string, ...> types in DTO files
// Reminds developers to verify proper OpenAPI configuration for SDK generation

engine biome(1.0)
language js(typescript)

// Match any Record<string, ...> type usage
`Record<string, $_>` where {
register_diagnostic(
span = $match,
severity = "warn",
message = "Verify @ApiProperty includes type: 'object' and additionalProperties: true for proper SDK generation"
)
}
1 change: 1 addition & 0 deletions biome.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"$schema": "https://biomejs.dev/schemas/2.2.0/schema.json",
"plugins": ["./biome-plugins/api-property-record-type.grit"],
"vcs": {
"enabled": true,
"clientKind": "git",
Expand Down
Loading