Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function Client(){this.a = 1;}
- Client.prototype.methodA = function(){}
- Client.prototype.methodB = function(){}
- function SubClient = function(){}
- Subclient.prototype.methodA = function(){}
- var a = new Client() ;
- a.SubClient.methodA() ;
- //Doesn't work - this.a is undefined
- Client.prototype.SubClient = {methodA: function(){}}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement