#1
  1. No Profile Picture
    Contributing User
    Devshed Novice (500 - 999 posts)

    Join Date
    Sep 2006
    Posts
    660
    Rep Power
    32

    Javascript use Objected Oriented Development & similar to Visual C# textbook?


    I have an option of studying Object Oriented Development course only but my interests are Web Design/Development in HTML, PHP, MySQL and Javascript.

    Wondering whether doing this course and reading the textbook Visual C# 2010 How to Program 4th Edition will be useful in Javascript??

    Wondering whether the skills I learn here is transferable or similar in some ways and beneficial??

    Anyone here use these skills when programming for Javascript and does OOP play a role to it??
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2012
    Posts
    74
    Rep Power
    19
    JavaScript is not an OOP language by definition, but a prototypical language. Reading on C# to understand Javascript would only let you understand basic programming elements like loops and control statements.

    If you want a good book on javascript, read:

    Title: JavaScript: The Good Parts
    ISBN: 978-0-596-51774-8
    Author: Douglas Crockford
  4. #3
  5. --
    Devshed Expert (3500 - 3999 posts)

    Join Date
    Jul 2012
    Posts
    3,959
    Rep Power
    1014
    Hi,

    JavaScript is an object-oriented language. Just because it uses a different inheritance model than Java, C# and whatever doesn't make it less object-oriented -- in fact, I think it's one of the more elegant and "pure" OOP languages.

    I also disagree with the statement that knowing C# won't help you with JavaScript. The key thing is to understand OOP (which many people don't) and programming in general. Once you do, transferring to another OOP language won't be that hard. Sure, they are all a little different, you still have to learn the syntax and quirks of each language. But the core concept is always the same.

    Personally, I'm actually a big fan of looking into other languages and concepts and not just staying in a particular niche. There are so many other great languages apart from the usual stuff like PHP, JavaScript etc.
  6. #4
  7. No Profile Picture
    Lost in code
    Devshed Supreme Being (6500+ posts)

    Join Date
    Dec 2004
    Posts
    8,316
    Rep Power
    7170
    JavaScript is not an OOP language by definition, but a prototypical language
    Actually by definition it's both.

    However, I'm pretty sure C# is not a prototype-based language, which means that a course in C# will be substantially less useful for learning JavaScript OOP than it will be for learning PHP OOP.

    As previously mentioned, the concepts of object oriented design are the same in both JavaScript and C#, but the concepts of the implementation are totally different because JavaScript uses prototypes and C# uses classes. So, after your C# class, you should have no problem designing a class inheritance diagram that would make complete sense to a JavaScript programmer, but if you sat down to actually implement it you would have no idea where to begin because JavaScript doesn't have classes.

    You would still have an easier time learning OOP in JavaScript if you knew it in any other language though.

    Comments on this post

    • Aurum84 agrees : Agree!
    PHP FAQ

    Originally Posted by Spad
    Ah USB, the only rectangular connector where you have to make 3 attempts before you get it the right way around
  8. #5
  9. No Profile Picture
    Contributing User
    Devshed Novice (500 - 999 posts)

    Join Date
    Sep 2006
    Posts
    660
    Rep Power
    32
    Thanks guys : )

IMN logo majestic logo threadwatch logo seochat tools logo