Before entring into the subject, we have to know that JavaScript is a dynamic scripting language. It is lightweight and most commonly used as a part of web pages, whose implementations allow client-side script to interact with the user and make dynamic pages. It is an interpreted programming language with object-oriented capabilities. Nowdays it used also on Back-end not only on Front-end.
In web, especially in Front-end: we have two kinds of scripts fonctionalities: DOM and BOM
Javascript DOM is acronym of Document object model, we use it to taraversing into elements, parents, and childs in HTML, like:
we have a div inside it we have three paragraphs and one span, with javascript dom we can select all childs of this div except span, and we can edit them with it.
Javascript BOM : is the acronym of Browser Object Model.
The Browser Object Model (BOM) is a browser-specific convention referring to all the objects exposed by the web browser. The BOM allows JavaScript to “interact with” the browser.
The object of window represents a browser window and all its corresponding features. A window object is created automatically by the browser itself.Java Script’s window.screen object contains information about the user’s screen. It can also be written without the window prefix.
Javascript DOM & BOM
Reviewed by Jugurtha Gc
on
août 03, 2020
Rating:
Aucun commentaire: