DEV Community

[Comment from a deleted post]
Collapse
 
hasnaindev profile image
Muhammad Hasnain

Vanilla JS refers to pure JavaScript and non-vanilla JS may refer to JavaScript frameworks, libraries, supersets (TypeScript) etc.

I also want to make clear that Vanilla JS is not DOM. DOM (Document Object Model) is a language independent interface that helps you manipulate XML or HTML type documents. Meaning, you could use any language to INTERACT with DOM.

The same goes for vanilla JS. It is used to interact and manipulate DOM but it is not DOM itself. JavaScript is a programming language capable of creating desktop and native applications.

Collapse
 
ironcladdev profile image
Conner Ow

Thanks, man. This was really helpful

Collapse
 
sergix profile image
Peyton McGinnis

What's an example separate from JavaScript of interacting with the DOM besides the browser's own rendering engine?

Collapse
 
hasnaindev profile image
Muhammad Hasnain

I don't understand what you mean but will answer according to what I did understand. An example of JavaScript interacting with DOM is, "document.getElementById." That's it. This method gets you an element which you may interact with, modify and remove.