Is there a small, lightweight solution for javascript class inheritance that will work well on both client and server side (node.js)? I’m not wanting a big library, just something that will allow me to declare a constructor and some methods, then have the ability for a class to inherit that.
Is there a small, lightweight solution for javascript class inheritance that will work well
Share
John Resig outlines a simple inheritance framework in about 25 lines of code here. I have seen it used to good effect.
You can use it like this: