Back to all reviewers

Semantic naming consistency

elie222/inbox-zero
Based on 2 comments
Prisma

Ensure all model and field names semantically reflect their actual purpose and maintain consistency with their usage throughout the codebase: 1. Choose names that accurately represent the entity's role without misleading prefixes.

Naming Conventions Prisma

Reviewer Prompt

Ensure all model and field names semantically reflect their actual purpose and maintain consistency with their usage throughout the codebase:

  1. Choose names that accurately represent the entity’s role without misleading prefixes.
  2. Verify correct spelling in all identifiers.
  3. Ensure data types match the documented usage patterns.

Example:

// Misleading model name with inappropriate type
- model UserFrequency {
-   timeOfDay DateTime?  // Comment says only time portion used
-   lastOcurrenceAt DateTime?  // Spelling error
- }

// Improved semantic naming and type consistency
+ model Schedule {
+   timeOfDay String?  // Stores time in "HH:mm" format as documented
+   lastOccurrenceAt DateTime?  // Correct spelling
+ }

This standard helps prevent confusion, improves code readability, and reduces the cognitive load for developers working with your schema.

2
Comments Analyzed
Prisma
Primary Language
Naming Conventions
Category

Source Discussions