a few examples of the many javascript design patterns