chapter31

development in a land far far away…

at the moment

History is not what happened. History is what was written down.

We all know that we should liberally comment our code to allow other developers (and yourself) to quickly and easily find out what a particular section of code does. But what about a comment block at the top of the page so anybody can (at a glance) determine template specific information?

Here is an example of what I use at the top of my pages, this is pretty standard but I know a lot of people don’t do it.


I find the best thing is to either have this as part of a template for a new .cfm file, or as a snippet for easy access. I actually use snippets with built-in and custom snippet variables for the comment options.

The snippet I use for cfeclipse is:


Note the custom variable $${Purpose:} as well as the built-in snippet variables like $${CURRENTFILE}. You can read more about snippet variables here.


Related Pages

Leave a Reply