mirror of
https://github.com/status-im/status-react.git
synced 2025-01-09 18:46:19 +00:00
7f960f9be5
This commit adds a custom linter to verify i18n/label is called with a qualified keyword, like :t/foo. More sophisticated linters are possible too. We also set the stage for other developers to consider more lint automation instead of manually reviewing conventions in PRs. If you want to understand how to write custom linters, check out https://github.com/clj-kondo/clj-kondo/blob/master/doc/hooks.md. You can fire the Clojure JVM REPL in status-mobile and play with the clj-kondo hook too, it works beautifully. Why do we care? By making sure all translation keywords are qualified with "t", it is trivial to grep or replace them because they're unique in the repo, and can't be confused with other words if you search by ":t/<something>". Note: It's a best practice to commit clj-kondo configuration from external libraries in the .clj-kondo directory. The directory .clj-kondo/babashka is auto-generated, that's why it was added.