Object Orientation In JavaScript II [Inheritance](aspxwizard.net)

submitted by bo2bo2bo2bo2(570) 4 years, 1 month ago

well there are two ways inheritance can be implemented in JavaScript

2 comments |category: |Views: 2

tags: another

new Add a live kick counter to your blog >> liveImage

You can even customize the image by choosing your own colors, and then clicking the button below to update the preview and the html code:

  • "Kick It" text
  • "Kick It" background
  • kick count text
  • kick count background
  • border

Simply copy and paste this HTML into your blog post.


Users who kicked this story:
Comments:

posted by ashmindashmind(775) 4 years, 1 month ago 0

This and a previous post are the least performant and recommended ways to do OOP in JS.
The correct way is to use prototypes.

Even the IE team recommends it:
http://blogs.msdn.com/ie/archive/2007/01/04/ie-jscript-performance-recommendations-part-3-javascript-code-inefficiencies.aspx

I appreciate author's effort, but it is a pity a bad practice got it to the front page.

Reply

posted by bo2bo2bo2bo2(570) 4 years, 1 month ago 0

i actually enjoyed the IE blog post i particularly liked the comments of developers :D

Reply

information Login or create an account to comment on this story