JSFiddle - React, Tailwind, and code Playground
by HYEONGJINKIM
JavaScript
var nhn = nhn ||{};
nhn.util = nhn.util || {};
nhn.util.hello = function(options){
$.extend(this, options || {});
this.init();
};
nhn.util.hello2 = function(options){
//$.extend(this, options || {});
$.extend(this, nhn.util.hello);
$.extend(this, options || {});
this.init();
};
nhn.util.hello.prototype = {
init : function(){
console.log("hello init");
},
hello : function(){
console.log("hello hello");
}
};
nhn.util.hello2.prototype = {
init : function(){
console.log("hello2 init");
this.hello();
this.hi();
},
hello : function(){
console.log("hello2 hello");
},
hi : function(){
console.log("hello2 hi");
}
};
console.log(new nhn.util.hello2());
//var hello = new nhn.util.hello();