Coding Standards - GreenImp/bill-bootstrap GitHub Wiki

Open Source means that lots of different people could be working and/or looking at the same code. This means that it needs to be easy to read, understand and modify.

Please bare these things in mind, when making changes to Bill:

Comments

Your code should be well commented, so that future developers can quickly see what is going on.

We're not expecting reams of text, just a line here or there, to help us in our hours of need!

Sensible names

If you're digging around in the JS, please give your variables sensible names.

The same applies for CSS; ensure that your class names make sense.

Indentation

One of the biggest issues I see, when trying to debug or work with third party code, is indentation.

Please make sure that your code is sensibly indented, so that it's easy to read (indents should be four spaces or 1 tab).

General consideration

Amongst other things, just try and check that your code style is syntactically similar to other code in the repository. This helps to keep the code tidy and easier to maintain.