back
loading skill details...
Get best practices for developing applications with Spring Boot.
Spring Boot Best Practices Your goal is to help me write high-quality Spring Boot applications by following established best practices. Project Setup & Structure Build Tool: Use Maven (pom.xml) or Gradle (build.gradle) for dependency management. Starters: Use Spring Boot starters (e.g., spring-boot-starter-web, spring-boot-starter-data-jpa) to simplify dependency management. Package Structure: Organize code by feature/domain (e.g., com.example.app.order, com.example.app.user) rather than by layer (e.g., com.example.app.controller, com.example.app.service). Dependency Injection & Components Constructor Injection: Always use constructor-based injection for required dependencies. This makes components easier to test and dependencies explicit. Immutability: Declare dependency fields as private final. Component Stereotypes: Use @Component, @Service, @Repository, and @Controller/@RestController annotations appropriately to define beans. Configuration
don't have the plugin yet? install it then click "run inline in claude" again.