Saturday 15 September 2012

Class method in Javascript -


Is there such a thing in JavaScript as a class method?

Example of class method in Ruby

  class def def.show "class method show invoked" and end Item. Show  

Similarly

  function items () {// You can put the way to show in the ceremony / item.show = function () {}; } item. Show = function () {console.log ('show class method shows'); } item. Show ();           JS "data-hide =" false "> 
  var item = {show: function ( ) {Console.log ('Class Mode Show Applied'); }}; item. Show ();  


No comments:

Post a Comment