Posted By

vlarsson on 05/31/12


Tagged


Versions (?)

Who likes this?

3 people have marked this snippet as a favorite

equi
hurcy
o0110o


Code


 / Published in: JavaScript
 

Class structure

  1. var ProjectName = {};
  2.  
  3. /* Does stuff */
  4. ProjectName.stuff = {
  5.  
  6. variable : null,
  7.  
  8. init: function() {
  9. this.setBehavior();
  10. },
  11.  
  12. setBehavior: function() {
  13. // do something
  14. }
  15. };
  16.  
  17. $(document).ready(function() {
  18. ProjectName.stuff.init();
  19. });

Report this snippet  

You need to login to post a comment.