kotlin-convention
Installation
SKILL.md
Kotlin Convention
Overview
This skill defines idiomatic Kotlin conventions for Android projects: naming, null safety, data modeling, functional patterns, and language features to embrace or avoid.
Naming
| Element | Convention | Example |
|---|---|---|
| Class / Interface / Object | PascalCase | OrderRepository, UserMapper |
| Function / Variable | camelCase | fetchUser(), currentState |
Constant (const val, object val) |
SCREAMING_SNAKE_CASE | MAX_RETRY_COUNT |
| Package | lowercase, dot-separated | com.example.feature.order |
| Extension function | camelCase, descriptive | String.isValidEmail() |
| Test function | backtick sentence | `SHOULD return error WHEN network fails` |