Understanding the DOM

Document Object Model


Understanding the DOM
Understanding the DOM
CC BY-NC-SA

Book Details

Author Tania Rascia
Publisher DigitalOcean
Published 2020
Edition 1
Paperback 126 pages
Language English
ISBN-13 9780999773093
ISBN-10 0999773097
License Creative Commons Attribution-NonCommercial-ShareAlike

Book Description

JavaScript is the de facto programming language of the web, but the language itself does not include any built-in method for working with input/output (I/O), such as graphics display and sound. Instead, the web browser provides an API for accessing the HTML document in a tree structure known as the Document Object Model (DOM). The combination of JavaScript and the DOM is what allows us to create interactive, dynamic websites.

Many modern frameworks, such as React, Vue, and Svelte abstract away much of the DOM from the developer, but frameworks also use the DOM under the hood. The JavaScript library jQuery was also created to make working with the DOM easier, but the modern development practice is to work with the DOM directly. In order to be a proficient web developer, having a deep understanding of what the DOM is and how to work with it is essential. The goal of this book is to provide a base understanding of the DOM, as well as explore examples of the most common and useful methods for interacting with the DOM.

The topics that it covers include:
- The DOM and DOM tree structure;
- How to access, traverse, and modify nodes and elements in the DOM;
- How to modify attributes, classes, and styles in the DOM;
- Use events to make interactive, dynamic websites.

Each chapter is self-contained and can be followed independently of the others. However, if you are not yet familiar with the concept of the DOM and DOM tree, it is recommended that you read the introductory chapters first.


This book is available under a Creative Commons Attribution-NonCommercial-ShareAlike license (CC BY-NC-SA), which means that you are free to copy, distribute, and modify it, as long as you credit the original author, don't use it for commercial purposes, and share any adaptations under the same license.

If you enjoyed the book and would like to support the author, you can purchase a printed copy (hardcover or paperback) from official retailers.

Download and Read Links

PDF

Share This Book

[localhost]# find . -name "*Similar_Books*"


JavaScript Bible, 4th Edition

JavaScript

Greatly enhanced and updated from the third edition, this is the title any JavaScripter cannot afford to be without! JavaScript Bible, 4th Edition covers the new powerful functionality JavaScript will gain with the release of new revs of Internet Explorer and Netscape Communicator. This book features essential new JS information, additional ready-t

XcalableMP PGAS Programming Language

XcalableMP is a directive-based parallel programming language based on Fortran and C, supporting a Partitioned Global Address Space (PGAS) model for distributed memory parallel systems. This open book presents XcalableMP language from its programming model and basic concept to the experience and performance of applications described in XcalableMP.�

The Nature of Code

Java

How can we capture the unpredictable evolutionary and emergent properties of nature in software? How can understanding the mathematical principles behind our physical world help us to create digital worlds? This book focuses on a range of programming strategies and techniques behind computer simulations of natural systems, from elementary concepts

Rational Cybersecurity for Business

Use the guidance in this comprehensive field guide to gain the support of your top executives for aligning a rational cybersecurity plan with your business. You will learn how to improve working relationships with stakeholders in complex digital businesses, IT, and development environments. You will know how to prioritize your security program, and

Asterisk: The Future of Telephony, 2nd Edition

Asterisk

This bestselling book is now the standard guide to building phone systems with Asterisk, the open source IP PBX that has traditional telephony providers running scared! Revised for the 1.4 release of the software, the new edition of Asterisk: The Future of Telephony reveals how you can save money on equipment and support, and finally be in control

The Computers That Made Britain

The home computer boom of the 1980s brought with it now iconic machines such as the ZX Spectrum, BBC Micro, and Commodore 64. Those machines would inspire a generation. Written by Tim Danton. The Computers That Made Britain (300 pages, hardback) tells the story of 19 of those computers - and what happened behind the scenes. With dozens of new inter