GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing flatcoding.com — JavaScript Introduction: What is JavaScript? - FlatCoding Home JavaScript Introduction: What is JavaScript?
Table of ContentThe current essay is devoted to the basic principles and introduction of JavaScript. This language no longer needs to be introduced since it has become integral to any web development. Everybody knows that JavaScript is not that easy to IGNORE. Read this article if you want to understand the core principles of Javascript from getting to know its key structure. And also you will know how it helps create MOVABLE, MORE INTERESTING, and TASTIC content. For all the wannabe programmers out there, or if you want to improve your web programming prowess. This article will form a solid ground in Javascript targeting the relevant notions and ideas needed for web app development. In the following section, you will understand what JavaScript is, so let’s move on to it. What JavaScript MeansJavaScript is an interpreted, high-level programming that is used to build dynamic and interactive features on web pages. Web browsers and page JavaScript web-interactive content and features. Such as multimedia, games, dynamic content updates, and validation, are made possible with this technology. JavaScript is indispensable both on the client side and server side. It is on the client side that the script is executed in the browser. It enables interaction with the web page thus no page has to be loaded. This therefore makes the websites easier and more pleasant to use. There also exists server-side scripting in which scripts are written in JavaScript using environments like Node.js to operate the server, databases, and web pages. This makes JavaScript a tool that can be employed in the development process at both the front and the backend stages since both the front-end and back-end interphase with the application. In the next section, you will take an overview of the JavaScript history. JavaScript HistoryBefore getting started in the history overview, JavaScript is only one language. And there is no language else to do its job, especially in the front-end stage. That’s all. Before JavaScript, web pages were only static pages and were lacking for dynamic procedures. So they decided to develop a scripting language for the Netscape Navigator. The Netscape team was thinking of collaborating with Sun Microsystems to use their Java Programming language with the Netscape tool. But that was failed for some unknown reasons. They decided to hire someone else to do this task, he called Brendan Eich, and let me say, that was the greatest decision ever made in history. Brendan Eich started the task and generated the first version of the scripting language in 1995 and embedded it into the Netscape version 2. Live ScriptThe language syntaxes were similar to syntaxes of the Java programming language, and its interpreter was called “LiveScript”. Eich was thinking of The name for his new scripting language. At this time Java was in hot demand and its popularity was officially spread. So he named his new scripting language with JavaScript name. And that was for a marketing ploy. JScriptMicrosoft takes over to generate its new Internet Explorer browser and that start a new war for browsers, against Netscape Navigator company. Microsoft team released their scripting language in 1996 to embed it with Internet Explorer, they named it “JScript”. This version supported HTML markups and CSS. During this period, most of the developers weren’t able to develop their websites in two browsers to have the same design in both. It was a big change in the design and structures of two both. So, this point leads Netscape and Microsoft to create other attractive sentences and slogans to do a ploy marketing for each other. Netscape used the slogan “best viewed in Netscape”, while Microsoft used “best viewed in Internet Explorer”. ECMA ScriptTo finish the slogan war. The Netscape company created a standard specification for the first ECMAScript language, and that was in 1997. During several years, they released many versions of the ECMAScript language each year with a new version starting in 1998 and ending in 2000 with the name ECMAScript 4. But Microsoft was not standing idly because its Internet Explorer was in spread. They reached 95% of the market. That means Microsoft JScript became the standard specification for the client side of the web application. In 2000 the ECMAScript was stopped with version 4. Because JScript became more popular than ECMAScript, Microsoft won. ECMA Script and MacromediaIn 2004, Mozilla continued the challenge and released their new browser called “Firefox”, they improved this browser with ECMAScript 4 of the Netscape Navigator and did many other features according to the ECMA International standard. This browser started to spread, and it became challenging for Google company and Microsoft. V8 JavaScript EngineIn 2008 Google started a new challenge and released the Google Chrome browser with its v8 JavaScript engine. This browser was faster than Google Chrome competitors. Because they were dependent on just-in-time compilation. In the next section, we will focus on the V8 JavaScript engine of the Chrome browser. Let’s dive right in. How the V8 JavaScript Engine WorksV8 engine is a Google project which is an open source created to do a high performance for the JavaScript programming language. The V8 engine is written in C++ programming language and implemented with two phases which are ECMAScript and WebAssembly. Additionally, the v8 engine works with major operating systems such as Windows, macOS, Linux, and so many others. Anyway, the mission of the V8 JavaScript engine is to translate the source code into binary bits (the machine code). And here, we are going to cover these phases. But before getting started, you have to know the difference between compiler and Interpreter. The Lexical TokensThe first step is receiving the source code from the server. Then it starts to analyze it according to some instructions in the lexical analysis and then generates a string containing the sequence of Lexical Tokens. This phase is also called a scanner. The ParserThe parser receives the sequence of tokens and generates the Abstract Syntax Tree (AST) which represents those tokens in a big structure. The InterpreterOnce it receives the AST, the Ignition interpreter starts to generate the bytecode and that was produced from the AST. Then it sends bytecodes to TurboFan, and here TurboFan converts these bytecodes into binary bits which is the machine code. On the other hand, the V8 engine has another thing called a Just-In-Time compiler to convert ECMAScript into native machine code before the execution. The compiled code is another optimization or (re-optimized) to be a highly optimized binary bit or machine code. If incorrect things are happening during this stage. It de-optimizes it and returns it to the interpreter to re-evaluate. That was an overview of the V8 JavaScript engine work from the top. In next section, you will learn more about JavaScript Capabilities and Limitations. Capabilities and Limitations of In-Browser JavaScriptCapabilities of In-Browser JavaScript
Limitations of In-Browser JavaScript
In the next section, I am going to write a program with JavaScript. Only to show a dialog box with – a “Hello World !” message. Write your First Program with JavaScriptFirstly, you have to install an editor to allow you to write the JavaScript code. And then copy the below code. Then open it in the browser.
The result would be a popup box containing the – “Hello World !” message. Similar ReadsJavaScript Math.max(): How to Find the Highest Number Math.max() is a built-in JavaScript function that returns the highest number from a list of values. It has been part… JavaScript Math log: How it Works with Examples JavaScript Math.log() was added to help people find the natural log of a number. It solves real problems in science… JavaScript toString Function: How it Works with Examples The toString function in JavaScript converts a value to a string form without change. It works on numbers, arrays, and… JavaScript Coding Style Guide for Beginners JavaScript code follows some rules that help both new and old developers. A project without rules in code creates trouble… How Does JavaScript Work to Run Code in the Web Browser Click a button on a website. Something changes. A menu opens or a message pops up. That’s how JavaScript works.… Mocha JavaScript Test Framework: Guide and Examples Mocha is a JavaScript test framework for Node.js. It runs tests in sequence and shows results. It works with any… Math.sign in JavaScript: Check Number Signs JavaScript includes Math.sign to find out if a number is positive. It also helps detect negative values or zero. It… JavaScript for Loop: How to Iterate Arrays by Examples JavaScript runs code in different ways, but the for loop stays one of the most common tools. You use it… JavaScript for of Loop: Syntax and Examples The for...of loop appeared to solve the problem of complex loops over arrays and strings. It gives you a way… JavaScript Object Methods with Examples JavaScript object methods are simple ways to handle data inside objects. An object can hold many values, and methods give… onMarch 30, 2025
Write a Comment
|
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |