Guest User

Untitled

a guest
Jan 22nd, 2018
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.48 KB | None | 0 0
  1. //one.js
  2. var Module = (function(Module) {
  3.  
  4. this.variable = 3;
  5.  
  6. this.init = function() {
  7. console.log("init");
  8. };
  9.  
  10. return this;
  11.  
  12. }).call({});
  13.  
  14.  
  15. $(function() {
  16. Module.init();
  17. Module.Utils.init();
  18. });
  19.  
  20.  
  21. //two.js
  22. var Module = Module ? Module : {};
  23.  
  24. this.Utils = (function(Utils) {
  25.  
  26. this.init = function() {
  27. console.log("Module.Utils.init");
  28. };
  29.  
  30. return this;
  31.  
  32. }).call({});
Add Comment
Please, Sign In to add comment