Thomas Ummels is a freelance Javascript developer who created the web based Gantt chart tool www.tomsplanner.com. A Gantt chart application to create and share project schedules, project plannings and project timlines. Easier than MS Project and faster than Excel. No more messy Excel spreadsheets with tom'splanner Gantt chart templates. The Gantt chart software is almost entirely written in Javascript using the latest Front End technolgies including Jquery and ecluding Ext-js. Tom'splanner enables you to share your Gantt charts and project schedules online.

Freelance Front-End/Javascript | Creator of Gantt Chart Software Tom'splanner

Thursday, April 9, 2009

10 Checks Before Launching Your Javascript

Inspired by the the article 15 Essential Checks Before Launching Your Website a small list of simple checks to a avoid unnecessary errors when getting your js code in production.

It does not contain the plain good old best practice rules on how you write your js code but these checks are mainly about code snippets that help you develop and debug your code in a fast and easy way that should not be around in the live version.
  1. check for console statements (console.log, console.startTime....)
  2. check for debugger statements
  3. check your outcommented try catch statements
  4. check for large outcommented old code fragments. If you are at the stage of going live this might be the time to get rid of it.
  5. look for fixed url's which might work in the development environment but not on the production server
  6. if you are using google maps make sure you have an api key for the live server
  7. check for credentials in your comments or code (like usernames and passwords)
  8. when using javascript libraries or frameworks make sure you include the minified production version and not the fully commented debug version.
  9. off course the same goes for your own js files
  10. and this last check works for me personaly: check on the "TO DO" string in the js code. When I still need to do some work on a part of the code I always flag it with a //TO DO comment.
This list is probably far from complete. Anybody any suggestions?

Labels: , ,


 
Thomas Ummels, freelancer and senior Javascript developer. Creator of the Gantt chart software www.tomsplanner.com. A Gantt chart tool that anables you to share project timelines and Gantt charts online. An alternative for Excel templates and/or MS Project. It is faster than Excel. Gantt chart templates enable you to create Project plans and schedules fast and easy. The Gantt chart tool is written in Javascript using the latest Front End technolgies including Jquery and ecluding Ext-js. Although Thomas Ummels has extensive experience using the Extjs framework. Tom'splanner enables you to share your Gant charts and project schedules online.