Vous êtes sur la page 1sur 3

¿What is JavaScript?

JavaScript is a more popular programming language called as a scripting language. Its initial objective was to
program some behaviors on the web pages, encouraging the interaction of users and the realization of simple
automatisms on the client side. Today, modern web pages and HTML5 have caused the use of JavaScript to reach
levels of complexity and performance as great as other top-level languages.
The progress of JavaScript has been so great, that we not only find it on the web pages, but currently we also find it
in the operating systems for computers and devices, on the server and client side. This new vision of language has
left the idea of creating small programs responsible for carrying out actions within web pages.

With JavaScript, used in a web context, we can do all kinds of actions and interactions. Previously, it was only used
to validate forms, show dialog boxes and little else. Today it is the engine of the most popular applications on the
Internet. Facebook, Google, Twitter, Outlook, etc. Absolutely all the applications we enjoy every day have tons of
JavaScript in their core. Web 2.0 is based on the use of JavaScript to implement rich applications which are able to
perform all kinds of effects, user interfaces and asynchronous communication with the server through Ajax.

It is called the "client side" because where it runs is in the browser (Web Client), as it is on the contrary PHP,
which runs from the "Server Side". On the JavaScript side, the client is the browser which supports the processing
load. Thanks to its compatibility with all modern browsers, it has become a standard programming language on the
client side.
JavaScript is a robust programming language that can be applied in a doctype HTML document and used for
dynamic interactivity of websites. JavaScript is completely object oriented.

JavaScript Features

The main feature of JavaScript is the great ability to integrate seamlessly with the operating system and most web
browsers, offering absolute versatility, which very few languages have, and, to be executed on the client side,
lightens the load of the server, resulting in websites and applications quite light. The fact that it can be combined
with other web development tools, such as PHP, Cascading Style Sheets (CSS), among others, is a must.
JavaScript was designed with a syntax similar to C, although it adopts names and conventions from the Java
programming language. However, both have different purposes and semantics. For a web page to interact with
JavaScript, the implementation of the Document Object Model (DOM) is provided.
Since the ECMAScript 1 standard was released in June 1997, there have been more versions 2, 3, 4, 5 which is the
most used at present (version 4 was abandoned). In June 2015 the ECMAScript 6 version was closed and published

Imperative and structured:

The JavaScript programming language is compatible with much of the programming structure of C (such as: if
sentences (Conditional), For (loops), switch (sentences), etc.). With one exception, in part: in c, the scope of the
variables reaches the block in which they were defined; But JavaScript is not compatible with it, since the scope of
the variables is that of the function in which they were declared. In the 2015 ECMAScript version, this missing
compatibility with Block Scoping is added to the language by means of the reserved word "let". As in C, JavaScript
distinguishes between expressions and sentences. The syntactic difference with respect to C is the automatic
insertion of the semicolon, i.e. in JavaScript the semicolons, i.e. in JavaScript the semicolons that end a sentence
can be omitted.

Dynamic
Dynamic Typing:
As in most scripting languages, the type is associated with the value, not the variable. For example, an x variable at
a given time may be linked to a number and later linked to a string. JavaScript can check the type of an object,
including duck typing. One way to find out is to use the keyword type of.

Object:
JavaScript objects are associative arrays, enhanced with the inclusion of prototypes. The advantage is that
properties and their values can be created, changed or deleted at runtime. An object and its properties can be
enumerated by means of the instruction the loop for...in. The predefined objects in JavaScript are Function and
Date.

Evaluation at runtime:

JavaScript and the eval function allow you to evaluate expressions expressed as strings at runtime. It is
recommended that the function be used with caution and that the JSON.parse () function be chosen as much as
possible, as it is much safer.

Functional

First-class functions:

They are often referred to as first-class citizens; they are objects in themselves. They have methods and properties,
such as. call () and bind (). The nested function is defined as a function defined within another. It is created each
time the external function is invoked. Each function created forms a closure; which is obtained by evaluating an
environment containing one or more variables dependent on another external environment, thus including
constants, local variables and arguments of the calling external function.

JavaScript History

Was initially created by Brendan Eich, (co-founder of the Mozilla project, Mozilla Foundation and Mozilla
Corporation) of Netscape with the name Mocha, which was renamed to Live Script, to later be JavaScript. The
name changes coincided with the moment Netscape added Java technology compatibility to its Netscape Navigator
web browser in its 2002 version in December 1995. When it was given this name, there was a confusion that gave
the impression that the language was an extension of java and has been characterized by many as a marketing
strategy of Netscape to gain prestige and innovate in the field of new web programming languages.

Reasons to use JavaScript:

1*It´s easy to get started with him:


As there is nothing to configure and install and there are no prerequisites of any kind there is no programming
language that is so up to date at anyone's fingertips. The same browser you use has everything you need to start
testing JavaScript code.

2*It´s a versatile language:

Although it's simpler than other languages, it doesn't mean you're simple or unsophisticated. One of the beauties of
language is that it doesn't restrict you to a single programming style. So, we can say that JavaScript is both multi-
paradigm and is at the same time:
-A traditional procedural language.
-Imperative
-Functional
Object-oriented
-Event oriented

3*JavaScript is present everywhere:


JavaScript is present in virtually any field:
-Mobile Development
-Internet servers
-Databases
-Game Platforms
-In operating systems such as Windows and Linux.
The scope of this language is incredible.

Vous aimerez peut-être aussi