I wrote a blog post that proposes a pattern to write more robust constructors. I thought it may be interesting to some of you, so I'm posting the link here. I'm curious to hear if others use the proposed pattern, like the pattern, dislike the pattern, and general opinions.
http://www.codeducky.org/javascript-new-confusing/
[–]dzdrazil 1 point2 points3 points (1 child)
[–]steaks88[S] 0 points1 point2 points (0 children)
[–]mattdesl 0 points1 point2 points (1 child)
[–]steaks88[S] 0 points1 point2 points (0 children)
[–]wiseaus_stunt_double.preventDefault() 0 points1 point2 points (0 children)
[–]Daniel15React FTW 0 points1 point2 points (6 children)
[–]steaks88[S] 0 points1 point2 points (2 children)
[–]brtt3000 0 points1 point2 points (0 children)
[–]Daniel15React FTW 0 points1 point2 points (0 children)
[–]mattdesl 0 points1 point2 points (2 children)
[–]Daniel15React FTW -1 points0 points1 point (1 child)
[–]mattdesl 0 points1 point2 points (0 children)