What is the fastest way to learn javascript

What is the fastest way to learn javascript ? :slight_smile:

I watched some videos from tuts plus, but can’t understand how to code from scrach. Can you suggest any books. :slight_smile:

This sounds quite good: https://learnable.com/books/jsjavascript1

Eloquent JavaScript is a great, free online book that teaches JavaScript from the basics. It has some interactive exercises that let you try things out as you learn. There’s also the JavaScript course at [URL=“http://codecademy.com”]Codecademy, which teaches the basics and is good if you like to learn by doing.

For learning, I reckon that the Head First series of books make it easy to pick up what you need to know.
Head First JavaScript

We also have a thread here specifically about which books to read, where you can find a good shortlist of books to read too, along with other useful advice too.

There is no fastest way, You need to love JavaScript first.
Once you are fall in love with it, the rest are easy.

The thing to avoid is all the web sites, books and college classes that teach history of JavaScript - the way that it used to be written for Netscape 4 and earlier.

If the material makes reference to any of: document.write, document.all, document.layers, alert (other than for debugging), confirm, or prompt then move on because that resource is extremely out of date.

Modern JavaScript is (with few exceptions) attached to the bottom of the page just before the </body> tag. All variables will be declared at the top of each function with the entire script wrapped in an anonymous function to ensure that it doesn’t clash with any other scripts that might get added to the same page. Whichever resource that you use to start with may not show all the JavaScript that way to start with but it should have covered how to code that way by the time you get to the point where you are able to write useful scripts to use on live web pages.

All variables will be declared at the top of each function with the entire script wrapped in an anonymous function to ensure that it doesn’t clash with any other scripts that might get added to the same page. Whichever resource that you use to start with may not show all the JavaScript that way to start with but it should have covered how to code that way by the time you get to the point where you are able to write useful scripts to use on live web pages.

Felgall, do you have a page on your site that gives a demo of all those bits together?

If you like, here’s a basic template for the module pattern.


var MODULE = (function () {
    var my = {},
        privateVariable = 1;

    function privateMethod() {
        // ...
    }

    my.moduleProperty = 1;
    my.moduleMethod = function () {
        // ...
    };

    return my;
}());

It may also not be assigned to a global variable, if you don’t want to directly access things from it later on.

Brilliant. Thanks For the examples, guys. :slight_smile:

@felgall ;

Thanks for sharing dude.
I will re-view that.

By the way what’s the difference between the two below,

versus

?

What to you mean by What’s the difference? They are two different sites. What more is there to say? MDN is a major company site, and the other is felgall’s personal site.

@ralph_m ;
wow, that’s nice to know.
So that is his site. cool…
I will try to read his site.

Yes, although I’m pretty slow to understand JS, I do appreciate the efforts of people like felgall to help me out. :slight_smile:

The best way to learn anything is to start DOING it. { That is how I mastered Brain Surgery!!}
As you struggle and stumble with Javascript you can ask for help on Sitepoint. Those difficulties you overcome become the best learned lessons and the foundation of your knowledge.

I would like to also inject into the “side discussion” this great resource I just discovered! A neat tutorial paired with a ‘playground’ to test, experiment, try and learn.

I thinks no faster way.First you love java script.You can success.see many video uses youtube.Go torrent site and download many more video.

The difference that led to my creating javascriptexample.net is that the mozilla site is basically a reference while my site is my fourth attempt at writing a series of tutorials to teach JavaScript to beginners (the first three versions appeared on javascript.about.com during the seven years that I was writing about JavaScript for them - the New York Times owned about.com for most of the time I wrote for them so the fourth version of my tutorials is the first not on a site owned by a well known company).

I personally found the JavaScript track at Codecademy incredibly helpful (and it’s free which is nice too).

Learnable has a bunch of resources on Javascript too. Including:
Simply Javascript (eBook)
JavaScript Programming For The Web (Course)
The Art & Science of JavaScript (eBook)
Jump Start JavaScript (eBook)

I must admit I haven’t yet had a chance to read the Jump Start JavaScript book yet (though it’s sitting on my Kindle). But the ‘Jump Start’ titles are based around the idea that you can learn basic skills and get up to speed with a given topic over a weekend, so it’s probably a good starting point.

The best option to learn java is to read different books you can download free ebook from bookchums