Learning Javascript : Object Creation Patterns

There are majorly Four patterns to create an Object in Javascript. Constructor Pattern. Factory Pattern Prototype Pattern Dynamic Prototype Pattern. Constructor Pattern – http://jsbin.com/rejaca/3/edit?js,output Use this keyword to attach Don’t return anything.

Factory Pattern – http://jsbin.com/rejaca/edit?js,console Create Dummy Object Return this object after 

Prototype Pattern …

Read moreLearning Javascript : Object Creation Patterns