How to Run JavaScript
There are few ways to run JavaScript code.
Embed JavaScript in HTML
Browser JavaScript Console
- A great way to learn JavaScript is to run it in browser's JavaScript console.
- Browser console is also essential for debugging JavaScript.
Using Deno
- Deno is a JavaScript runtime and compiler, runs in terminal.
- Most versatile, flexible, powerful, for developing with JavaScript.
- It is also used in running web server or desktop app.
Using node.js
- node.js is a JavaScript runtime and compiler, runs in terminal.
- Ryan Dahl created node.js in 2009.
- He created a better version called deno in 2018.
I recommend Deno.