Nothing here yet.
Nothing here yet.
No blogs yet.
Neither, I use just objects. Some time ago I used Fn + Proto and if I would use the same approach now than Class would be fine but I'm trying to avoid the use of classes in javascript. This is simply not the right way, there are more natural ways for js. Just think about it, in js Fn + Proto or Class just create objects with methods and properties. You can do the same with simple object literals and mixing them (and/or use Object.create for prototypes - since the prototype object is also a simple object). I know someone could say that prototype performs better and he is right but it would matter only if you instantiate thousands of instances in very short time (in one request anim frame for example). For fewer instances object creation factories will work fine or a simple object if you need just one instance. There is a very good explanation from Kyle Simpson here: https://gist.github.com/getify/5572383#file-ex2-oloo-style-js I also recommend his work: You Don't Know JS https://github.com/getify/You-Dont-Know-JS/blob/master/this%20&%20object%20prototypes/README.md#you-dont-know-js-this--object-prototypes and his video series on Front End Masters - Advanced Javascript https://frontendmasters.com/courses/advanced-javascript/