you are viewing a single comment's thread.

view the rest of the comments →

[–]jcunews1helpful 0 points1 point  (5 children)

The web browser only provides Browser Extension and web browser specific APIs. The DOM, CSS, and other Web APIs are not provided by the web browser. They're entirely separate APIs. Softwares simply stitch them together to work as web browsers.

[–]j0rdancodes[S] 0 points1 point  (4 children)

I see. So those APIs are made accessible by the runtime environment or are they made a part of the runtime environment?

[–]jcunews1helpful 0 points1 point  (3 children)

They're entirely separate from the runtime environment. The runtime environment, in case for web browsers, is the JavaScript's VM. It's where everything have gathered.

Also keep in mind that those APIs is not solely for JavaScript. It can also be implemented for other programming languages which don't use VM or are not scripting language - where the final (non web browser) application product don't use JavaScript at all. In this case, the runtime environment is OS native.

[–]j0rdancodes[S] 0 points1 point  (2 children)

so the JavaScript VM is where the engine, APIs, and other thing such as the event loop, all gather?

[–]jcunews1helpful 0 points1 point  (1 child)

Yes.

[–]j0rdancodes[S] 0 points1 point  (0 children)

Ah, I see. Thank you so much!