Pinterest Stumbleupon Whatsapp

what is javascriptJavaScript has an interesting bit of history. Originally developed at Netscape as Mocha, it came to the forefront with official announcement in 1995. It was then developed independently by different parties, most notable of which was JScript by Microsoft.

Obviously a standardized implementation was needed, which led to its submission to ECMA international. Thus ECMAScript was formed. These days, most browsers support ECMA-262 which is also more commonly (and often vaguely) known as JavaScript.

What is Javascript? Javascript is rightly called the language of the Web. Each newer browser version pushes the bar higher in terms of JavaScript execution speeds. This is an important performance parameter these days as sites make extensive use of JavaScript. JavaScript led the Web 2.0 revolution with AJAX. Using JavaScript, sites can send HTTP requests behind the scenes and customize or update certain sections of the site, tailored to a particular user’s needs. This does away with complete page refreshes and makes the user interface a lot more powerful and user friendly.

Hello World of JavaScript

The Hello World example is almost customary to include when talking about programming languages. So here we go

document.write("Hello, World!");

You can also pop alert boxes just as easily with:
document.alert("Hello, World!");


what is javascript

Yeah, that is all you need. No need to include any file or import any packages. Everything that is needed to execute JavaScript is provided by the browser (or the client) so it is also called Client Side Scripting Language. Why client side? To answer this question, you would have to look into how JavaScript works.

How It Works

The browser fetches a page which might have embedded JavaScript as we saw above, or refers to a separate JavaScript file in which case that file is also fetched by the browser.

what is javascript

Next up, depending upon what you want your JavaScript code to do and how you structured it, it will either execute as soon as the file loads or wait for a triggering event (like a click, or load).


Finally, when it’s all good, the code is executed line by line. JavaScript is an interpreted language, which means you don’t need to compile the code into another form to execute it. All of the changes you make, instantly take effect.

Comparing Other Programming Languages

Contrary to what the name might suggest, JavaScript is actually very different to Java. There are some similarities in the syntax, but that’s about it. JavaScript is loosely typed (you don’t have to define the datatype of variables) while Java is not. JavaScript is mainly executed in a browser, where as Java can be used to create stand alone applications. Java has a much wider area of application as compared to JavaScript which largely lives inside the browser.

JavaScript is Object Oriented but unlike other programming language that implement inheritance via classes, JavaScript does so via prototypes. JavaScript also has the largest install base (arguably) since it is bundled with all the major web browsers these days.

I have merely scratched the surface when you consider that it is a full blown programming language, and that it has all the buzz and develop going for it these days. There are plenty of JavaScript libraries, server side JavaScript and other projects that push the realms and applications of JavaScript to a whole new level. If you are starting out on JavaScript there are few tutorials that will help you along. Once you are up to speed and enjoy what you are doing, you can pick up The Rhino Book and enhance your JavaScript skills even further.

Have you ever tried to program with JavaScript? How was the experience?

Leave a Reply

Your email address will not be published. Required fields are marked *