JavaScript

From WikiMD's Wellness Encyclopedia

JavaScript
ParadigmMulti-paradigm: event-driven, functional, imperative
DeveloperNetscape, Mozilla Foundation
Typing disciplineDynamic
Website[Official ECMAScript Website]
Influenced by
Self, Scheme, Java
Influenced
TypeScript, CoffeeScript


JavaScript (often abbreviated as JS) is a high-level, interpreted programming language that conforms to the ECMAScript specification. JavaScript has become one of the core technologies of the World Wide Web, alongside HTML and CSS, as it enables interactive web pages and is thus an essential part of web applications. The vast majority of websites use JavaScript, and all major web browsers have a dedicated JavaScript engine to execute it.

History[edit | edit source]

JavaScript was created in 1995 by Brendan Eich while he was an engineer at Netscape. Originally developed under the name Mocha, the language was later renamed to LiveScript, and finally to JavaScript, coinciding with the release of Netscape Navigator 2.0. Despite the name, JavaScript is almost entirely unrelated to the Java programming language, and the common naming is generally considered a marketing ploy by Netscape to capitalize on Java's popularity at the time.

Features[edit | edit source]

JavaScript is characterized by its dynamic typing, prototype-based object-orientation, and first-class functions. It is a multi-paradigm language, supporting imperative, event-driven, and functional programming styles.

Syntax and semantics[edit | edit source]

JavaScript's syntax is influenced by that of C, though it has fewer low-level facilities. JavaScript supports object-oriented programming with object prototypes, instead of classes (as in C++ or Java). However, with the introduction of ES6 (ECMAScript 2015), JavaScript now supports class-based object-oriented programming as well.

Runtime environment[edit | edit source]

JavaScript typically runs in a client-side environment (e.g., in a web browser), but it can also be used on the server-side, through environments such as Node.js. This dual capability allows for the development of full-fledged applications that are capable of interacting with a web server and a database.

Usage[edit | edit source]

JavaScript is used in many aspects of web development. It is used to provide dynamic behavior on websites (e.g., interactive forms, pop-ups, animations), to load content asynchronously via AJAX calls, and to build complex user interfaces with frameworks like React, Angular, and Vue.js.

Security[edit | edit source]

JavaScript can also be a vector for web security issues, particularly through cross-site scripting (XSS) attacks, where malicious scripts are injected into trusted websites. Modern development practices and frameworks strive to mitigate these risks through various techniques, including content security policies and sandboxing.

See also[edit | edit source]

References[edit | edit source]



Wiki.png

Navigation: Wellness - Encyclopedia - Health topics - Disease Index‏‎ - Drugs - World Directory - Gray's Anatomy - Keto diet - Recipes

Search WikiMD


Ad.Tired of being Overweight? Try W8MD's physician weight loss program.
Semaglutide (Ozempic / Wegovy and Tirzepatide (Mounjaro / Zepbound) available.
Advertise on WikiMD

WikiMD is not a substitute for professional medical advice. See full disclaimer.

Credits:Most images are courtesy of Wikimedia commons, and templates Wikipedia, licensed under CC BY SA or similar.

Contributors: Prab R. Tumpati, MD