does spket support closure??

Get help with Spket IDE.
Post Reply
bokix
Posts: 1
Joined: Tue Jan 26, 2010 10:20 am

does spket support closure??

Post by bokix » Tue Jan 26, 2010 10:44 am

I hava 2 javascript files:

Code: Select all

 
-----------[common.js]------
(function(){
  Common = {
       interFace1 : function(){...},
       interFace2 : function(){...}
   };

   function _inner(){
      return "inner";
  };
})();
--------------------------------

---------[test.js]-------------
/*
 * @include "common.js"
 */

  Common.interFace1(); // content assist can not work!
------------------------------
 
The Common is not recognized by the content assist in test.js, but, if I use jquery,and include a jquery plugin file, content assist can work correct, for example:

Code: Select all

------[jquery.test.js]---
(function($){

     $.test = {...}

})(jQuery);
---------------------------

---------[test.js]-------------
/*
 * @include "jquery.test.js"
 */

  $.test  // content assist work correct,  why?????
------------------------------
does spket support closure??

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest