Please use descriptive full word variable names.
- In the lifecycle of most projects, fixing bugs and maintaining current features end up taking 50%+ of total engineering time.
- Our goal is to create a code base that is easy to understand, making fixing bugs and maintaining current features as painless as possible. We will have many engineers working with this code, and we want to be welcoming to engineers who are new to the project.
- Short variable names can often create confusion, where a new engineer needs to spend time figuring out what a short variable name actually means. (Ex/ Please use “person” instead of “per” or “p”.) For this project please use descriptive full word variable names.
- Fellow engineers should be able to zoom around the code and not get stopped with riddles created by short names.
- Please name variables all lower case with "_" in between words.
- Please use full words instead of abbreviations (Ex/ Please use “person” instead of “per” or “p”.)
- Exception: Please use lower case camel case ("camelCaseLettering") for local variables passed into components as properties, unless you are passing a widely used data variable (like "google_civic_election_id"), especially if it is passed around to multiple components.
-
Asset names should be all lower case (ex/ "lower.png")
-
If a name has multiple words, use "-" between words in the name (ex/ "lower-case.png")
-
If sequential, put order word + number at start of name (ex/ "slide1-")
-
For fixed size images, include width and height at the end of the name (ex/ "-200x150"). Does not apply to svg files.
-
If an image is still a "first draft", lets add "-draft" to the name + version number (ex/ "slide3-connect-list-with-photos-draft1-300x370.png")
-
If adding images that are meant to be used in one limited area of the App, please put them in their own folder within "src/img/global".
Examples of good names:
slide1-ballot-simple.svg
slide3-connect-list-with-photos-draft1-300x370.png
Examples of names we avoid:
Image1.svg
If you're actively working on an issue, please comment in the issue thread stating that you're working on a fix, or (if you're an official contributor) assign it to yourself.
This way, others will know they shouldn't try to work on a fix at the same time.
We use SemVer for version numbers. More info: Versions: Release Names vs Version Numbers