From bd32a9573b71a41a3050a8c031aa4e058b81eb25 Mon Sep 17 00:00:00 2001 From: Skyler Grey Date: Sat, 18 May 2024 21:49:26 +0000 Subject: [PATCH] docs: update contributing/formatting/code --- contributing/formatting/code.md | 37 ++++++++++++++++++++++++++++----- 1 file changed, 32 insertions(+), 5 deletions(-) diff --git a/contributing/formatting/code.md b/contributing/formatting/code.md index 516ee35..48aa492 100644 --- a/contributing/formatting/code.md +++ b/contributing/formatting/code.md @@ -1,14 +1,41 @@ --- title: Code Standards description: -published: false -date: 2024-05-16T22:26:43.218Z +published: true +date: 2024-05-18T21:49:25.429Z tags: editor: markdown dateCreated: 2024-05-16T22:18:45.623Z --- +# Use automated tools + +When writing files which contribute to the Aux project, you should use [our standard formatting and linting tools for your language](/contributing/formatting/tools). If there is not a tool designated on that page, you should use the tool which is most commonly used for your language and add it to [our standard formatting and linting tools page](/contributing/formatting/tools). + +> If your formatter or linter in default configuration disagrees with anything on this page, follow your formatter or linter. Ignore whatever guideline or guidelines on this page your linter has a differing default on. +{.is-warning} + +> You should not configure your tools to accept the behavior on this page if they do not by default. +{.is-danger} + # Naming -If your linter does not specify which naming convention to use please follow: -- Functions, variables, and other child items should use lowerCamelCase -- Classes, interfaces, and other parent items should use UpperCamelCase \ No newline at end of file + +If your formatter or linter does not specify which naming convention to use please follow: +- **Classes, interfaces, and other types should use `UpperCamelCase`** +- **Everything else, including functions and variables should use `lowerCamelCase`** + +# Tabs + +Because they allow different people to configure a different displayed width, please use **a single tab for indentation**. + +# Semicolons + +**Where semicolons are optional, please include them**. Not doing so can cause ambiguity in some cases, which can be hard to spot. + +# ...And your favorite formatting difference... + +If you come across a formatting choice that isn't covered, [please edit this page to add it](https://wiki.auxolotl.org/e/en/contributing/formatting/code). Please make any reasonable decision, it matters far more to be consistent than to be perfect. + +If your formatting preference is one that tends to be flame-warred about, please remember to be nice, respectful, and follow [the code of conduct](/agreements/code-of-conduct). + +If a formatting decision has been made against your preference, we're sorry. We still expect you to follow the decision for the sake of consistency. Please don't edit this page to change the decision. If you believe a decision on this page has been made in bad faith, please contact a member of the steering committee. \ No newline at end of file