What is JavaScript? A Blog about new technologies on the web.


What is JavaScript?

When I was working on my first personal project (I was learning how to use Parse.com to build a mobile application), I realized that I needed to learn JavaScript in order to do some super simple things, like making a button work. Since then I’ve been looking for the best resources to study this language, so here are some links that helped me.

What is JavaScript?

JavaScript is a scripting language used to add interactivity and functionality to web pages. A scripting language is similar to programming languages but has less functionality. There are three core technologies that help you create today’s modern websites: HTML and CSS are the markup languages that define structure and style, while JavaScript adds interactivity.

A good example of something you can do with JavaScript is adding an interactive map or video player in your page without having to refresh it.

What is JavaScript?

JavaScript is a programming language that allows you to implement complex things on web pages — every time a web page does more than just sit there and display static information for you to look at — displaying timely content updates, interactive maps, animated 2D/3D graphics, scrolling video jukeboxes, etc. — you can bet that JavaScript is probably involved. It is the third layer of the layer cake of standard web technologies, two of which (HTML and CSS) we have covered in much more detail in other parts of the Learning Area.

JavaScript is a multi-paradigm, dynamic language with types and operators, standard built-in objects, and methods. It has been standardized in the ECMAScript language specification.

JavaScript (JS) is a lightweight, interpreted programming language with object-oriented capabilities that allows developers to build interactivity into otherwise static HTML pages.

JavaScript is a scripting or programming language that allows you to implement complex things on web pages. Every time a web page does more than just sit there and display static information for you to look at — displaying timely content updates, interactive maps, animated 2D/3D graphics, scrolling video jukeboxes, etc. — you can bet that JavaScript is probably involved. It is the third layer of the layer cake of standard web technologies, two of which (HTML and CSS) we have covered in much more detail in other parts of the Learning Area.

JavaScript is a programming language. It’s used to create interactive web experiences. For example, you can use JavaScript to make your form validate before being submitted or to load new content into your webpage without having to reload the whole page.

JavaScript is also used in game development and mobile apps development.

JavaScript is often used together with HTML and CSS to add interactivity and behavior to websites.

JavaScript Exercises:

Here are some JavaScript exercises you can try at home before starting this course:

Introductory exercises:

W3Schools’ Online Editor will show you the result of your JavaScript code directly under the code. It’s very easy to use and at the same time it’s powerful! In this exercise, we will use the editor to learn how JavaScript works together with HTML and CSS. This is called DOM – Document Object Model.

W3Schools’ Online Editor will show you the result of your JavaScript code directly under the code. It’s very easy to use and at the same time it’s powerful! In this exercise, we will use the editor to learn how JavaScript works together with HTML and CSS. This is called DOM – Document Object Model.

JavaScript is a high-level, dynamic, untyped, and interpreted programming language. It has been standardized in the ECMAScript language specification. Alongside HTML and CSS, JavaScript is one of the three core technologies of World Wide Web content production; the majority of websites employ it, and all modern Web browsers support it without the need for plug-ins. JavaScript is prototype-based with first-class functions, making it a multi-paradigm language, supporting object-oriented, imperative, and functional programming styles.

JavaScript was influenced by many languages and was designed to look like Java, but to be easier for non-programmers to work with. It is also used in environments that are not web based, such as PDF documents, site-specific browsers and desktop widgets. Newer and faster JavaScript virtual machines (VMs) and platforms built upon them have also increased the popularity of JavaScript for server-side web applications. On the client side, developers have traditionally implemented JavaScript as an interpreted language, but more recent browsers perform just-in-time compilation.

JavaScript, the core programming language used in developing web applications and websites, has been around for nearly 20 years. It’s evolved from a simple scripting language to one that can accomplish complex tasks.

JavaScript is used in almost every website and web application. However, as with most languages, JavaScript has developed its own jargon. This can make learning the language feel like learning a new dialect of English!

One question that we’re often asked at Treehouse is “What does ‘vanilla’ mean in JavaScript?” Let’s dive into the meaning of vanilla JavaScript and why it’s important to learn.

JavaScript is a single threaded language that means it can handle one task at a time. So, what happens when you have to run multiple tasks? You use callback functions in JavaScript. These callbacks can be called synchronous or asynchronous callbacks.

However, the challenge with callbacks is that they get nested inside each other making the code hard to debug and maintain. This is the Callback Hell!

What is Callback Hell?

Callback hell refers to an anti-pattern wherein callbacks are nested inside other callbacks resulting in unreadable code. This makes it hard to understand and maintain. Imagine having 5 or more nested functions which are all dependent on each other. It’s hard to read and keep track of what’s going on. Let’s see an example of callback hell:

function doWork1(data, callback) {

// do something with data

callback();

}

function doWork2(data, callback) {

// do something with data

callback();

}

function doWork3(data, callback) {

// do something with data

callback();

}

function doWork4(data, callback) {

// do something with data

callback();

}


Leave a Reply

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