Coding Standards
Does your shop have a coding ‘standard’?
Steven Erat was asking on Twitter a few days ago for a link to the old ColdFusion MX Coding Guidelines and actually found a copy on the Wayback Machine.
While the old coding guidelines were a great reference, the last update was in 2005!
I mentioned to Steven that Luis maintains a great ColdFusion Standards & Best Practices document on the ColdBox wiki. Most people I mention this to are unaware this great resource is available.
Luis’ guide is a great resource to use ‘as is’ or as the start of your own standard. It covers quite a bit - here are just some examples:
- Naming & Conventions
- CFC Best Practices & Conventions
- Variable Scoping
- Application.cfc Best Pratices
- Race Conditions
- Do Not Abuse Pound Signs
- Use Consistent Code Formatting
Hopefully you have a wiki or something on your team for documentation. Add a link or copy and paste it and modify to your needs.