Standard Inheritance System for node.js and browsers (including IE6)?

Problem

I am looking for a Standard Inheritance System that can work in both node.js and browsers.

sys.inherits doesn’t work in old browsers (Object.create).

All js libraries (jquery, extjs, dojo…) have similar but diff inherit systems. (Don’t know which one is good for node.js)

Want to use one which is simple and may become the “standard” in the future (at least in node.js based system).

Any idea? Which one are you using?

Also found some interesting projects:

http://howtonode.org/prototypical-inheritance (Not good for IE)

http://jsclass.jcoglan.com/modules.html (Too large, too ruby?)

By the way, I am using require.js in frontend.

Thanks

Problem courtesy of: Eric Fong

Solution

Use node.js’ sys.inherits server side, use whatever your framework uses in the front end.

Keep it simple.

Solution courtesy of: Robin Duckett

View additional discussion.

Like what you read? Give Jamie Munro a round of applause.

From a quick cheer to a standing ovation, clap to show how much you enjoyed this story.