JS – OOP in JS, made simple

JavaScript seems to be the language for me for December. Although I am really working with VBA only, JS has really a lot to show. Thus, today I will simply write some easy OOP samples, that I can use later šŸ™‚

JS

So, the code for today does the following – it shows four messageboxes, each one with some information about an object.

We have two objects –Ā first_article and second_article and they are both from type Article. Type Article has two functions Ā – like_yourself_in_fb & info_about_article.Ā So, when you call each of them, you get a message box with someĀ information. Enough is enough, here comes the code:

Enjoy it in GitHub as well šŸ™‚

Tagged with: ,