Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejs
(function(moduleName,$,window,undefined){
…
}( window.moduleName = window.moduleName || {}, jQuery, window, undefined ));

(info) Here's an interesting article about that

Each module is its own file (eg. 'about.js') and the filename is the lowercase version of the module name, (so 'about.js' represents 'siteName.about' ), keeping any individual file legible and compartmentalized, and although were polluting the namespace, we're doing so responsibly. This may all change as we get into packing our frontend javascript differently (say using browserify, webpack or duo).

...