AndroidDev-social / DodoForMastodon

🐘 Mastodon client for Android, iOS and Desktop (JVM)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[FEAT]: Code Style, Conventions

crocsandcoffee opened this issue · comments

commented

Description

It was requested in #mastodon-client slack channel for documentation regarding code style and coding conventions.

This is just an "issue" to track that and for anyone to offer any input.

As a starting point I suggest we just use the default kotlin style guide for now, unless anyone feels strongly and wants to create a custom one that follows certain guidelines and can be included in the project and imported in workspaces.

Additional Information

No response

The project could enforce a code style with ktlint and Twitter's 😉 Compose Rules. Latter is really nice because it also catches common Compose errors / gotchas.

Maybe spotless with ktlint is an option.

Almost forgot - Danger to enforce some PR standards.

I know the default kotlin style guide says "Use four spaces for indentation" but I find it such an old fashioned formatting... is everyone agree not to change it to 2?

Why not use tabs? Then everyone can individually decide how indentation is rendered? 🔥 (let the flame wars begin 😉)