SHARE

Hey ninjas, in this JavaScript tutorial for beginners, we’ll make our very own object using the car analogy from the last lesson. I’ll show you how to create the object, add properties and methods, and finally how to use the shorthand notation to do this.

As always, if you have any questions, fire away :).

SUBSCRIBE TO CHANNEL – https://www.youtube.com/channel/UCW5YeuERMmlnqo4oq8vwUpg?sub_confirmation=1

========== JavaScript for Beginners Playlist ==========

https://www.youtube.com/playlist?list=PL4cUxeGkcC9i9Ae2D9Ee1RvylH38dKuET

========== CSS for Beginners Playlist ==========

https://www.youtube.com/playlist?list=PL4cUxeGkcC9gQeDH6xYhmO-db2mhoTSrT

========== HTML for Beginners Playlist ==========

https://www.youtube.com/playlist?list=PL4cUxeGkcC9ibZ2TSBaGGNrgh4ZgYE6Cc

========== The Net Ninja ============

For more front-end development tutorials & to black-belt your coding skills, head over to – https://www.youtube.com/channel/UCW5YeuERMmlnqo4oq8vwUpg or http://thenetninja.co.uk

========== Social Links ==========

Twitter – @TheNetNinja – https://twitter.com/thenetninjauk

12 COMMENTS

  1. Hi, I would like to ask is it a must to print something out from the function /methods as i had noticed that you would include console.log in the function or setting a value for the function. Is there a way of not printing anything using the method of:

    var myCar ={
    properties
    method

    };

  2. Hi great videos!!
    I have a question. maybe I'm stupid and did something wrong here.
    i got the result "undefined" when i make my code like this.

    var name = new Object();
    name.age = 50;
    name.lastName = "Jenny";
    name.age = "Johan";
    name.eyeColor = "blue";

    console.log(name.age);

    cant i use name as an variable to be an object or what did i do wrong here?

  3. var a= new Object();
    a.speed = 100;
    a.driver = 'dell';
    console.log(a.driver);

    (or)

    var a =
    {
    speed = 100;
    driver = 'dell';
    console.log(a.speed);
    }

    what's the difference?which one can i use?

LEAVE A REPLY

Please enter your comment!
Please enter your name here