I can’t stress enough the importance of clean code. It may take more time initially to carefully plan a web architecture, document, and comment code, but it’s always worth the initial planning in order to save a huge headache later. I don’t know how many projects that I have acquired that were so poorly coded that I had to start the project from scratch to work on it. Now I’m definitely not the best coder in the world, but I like to use best practices if I or someone else needs to come back to the project later for updates or changes.
A lot of time, people have a fixed bid on a project. The industry is competitive so people tend to go to the lowest bidder. Many times, in order for a programmer to hit his or her budget, he or she will save time by not organizing code well or documenting the system. While your application may work initially without clean code and documentation it is hard for someone to come in and add a feature it will take them more time to figure it out. Often times after an initial fixed bid a consultant will charge hourly to cover the time. So my advice to those starting a web application, you get what you pay for. I find hourly rates keep everyone honest. The programmers gets paid what they think they’re worth and the code ends up being a lot better if there aren’t as many time restraints. A good consultant will estimate the time accordingly, but as a client you must realize any changes or additions will take more time.
Clean code and documentation can help individual programmers as well as other coders. You may find it easier to update your site on your own if things are explained where someone with a little code experience can come in and see what’s going on. If you don’t know what you’re doing I would recommend hiring a professional to take care of your sites. He or she is a professional. He or she knows what to do if you hire the right one and it will save you a lot of time and money in the end.
Versioning systems are great for keeping code organized and a small part of a documentation system. Besides that it keeps a backup of all the versions of the code to roll back from a previous time. My versioning system of choice is Subversion, but CVS and many others are popular. If you don’t have one consider one.
Commenting and documentation inline or in read me files are important. It will help explain what is going on. Good coders will make sure to add it to the code. Make sure time is allocated for this. I know a lot of the time clients will want it done yesterday and commenting and documentation tend to be the corners cut in order to meet deadlines.
So to wrap things up, clean code and documentation is important. Organization and structure are important parts of code in order to update and add features. A versioning system is nice and highly recommended for backup of code revisions and small bits of documentation. Comments, read me files, and inline documentation is very useful for the future and for other programmers to pick up where the last one left off. I hope these tips are helpful to you and if anyone has additional questions are comments feel free to leave them. There should be a few more parts to this series. Make sure to check back and if you have a category to recommend suggest it.









