I’m trying to do a huge web application in javascript, and I think I must do it in an object oriented way if I don’t want to mess up everything.
So, I searched a lot and found lots of different ways to declare classes and make instances in JS, like environment variables, functions, functions in functions …
I would like to know what is the best way of achieving a big object oriented structure (a bit like Java/C# or other strongly object oriented languages) and more precisely how to declare static members which I can access in all the instances of a class.
Thank you very much
I’m trying to do a huge web application in javascript, and I think I
Share
Read “JavaScript – The Good Parts” and learn the module pattern by heart:
http://www.adequatelygood.com/2010/3/JavaScript-Module-Pattern-In-Depth