forked from EasyLearnCode/easylearncode
-
Notifications
You must be signed in to change notification settings - Fork 0
Quy tắc code
NamPNQ edited this page Dec 5, 2013
·
1 revision
##Python
- Sử dụng 4 dấu cách, không dùng tabs
- Tránh dấu cách dư thứa
- Luôn viết test
- Viết code đơn giản, đọc được
- Tránh viết một method dài, tách nó ra thành những chức năng riêng biệt
- Write fat models, skinny controllers.
- If you write migrations, make sure they are revertible.
- Use english words in the code.
- Naming convention is important part of making code readable.
- Name methods and variables according to what they do.
- Follow python conventions
- Use private methods for things that are not meant to be used by others.
##Javascript