Skip to content

Conventions

octogradiste edited this page Apr 11, 2024 · 6 revisions

Git

Branches

Use lowercase letters, - to separate words, and the prefix feature/ when developing a new feature.

Examples

  • feature/simple
  • feature/more-than-one-word

Commits

Start with a capital letter and use present tense. The first line should be a very short description of the commit. Optionally, longer explanations can be added after a blank line.

Example

Very short description in present tense

Optionally a longer explanation.
This might use multiple lines.

Code

Strings

All text displayed to the user should be extracted to the strings.xml resource. Use only lowercase letters and _ to separate words. Prefix with the name of the file.

Examples

  • login_screen_login_button_text
  • login_screen_email_label

Note

When your cursor is on a string, you can use the short-cut Alt+Enter then Extract string resource to extract the string.

Interfaces and Implementations

Suffix the implementation with Impl if there is only one. Otherwise, use a prefix which defines the implementation.

Example

  • Interface Repository and implementation RepositoryImpl
  • Interface AuthenticationService and implementations FirebaseAuthenticationService, SupabaseAuthenticationService
Clone this wiki locally