Running and Installing Scripts

Learn to run and access local and remote web servers of Deno, and learn to use the install command for scripts.

Run a local and remote web server

In one of his first talks, and in Deno’s first version release notes Dahl used the following sentence: “Deno is like a web browser for command-line scripts.”

This sentence makes more and more sense once we start using Deno. Let’s explore it a little further.

When we access a URL, a browser runs the code there. It interprets the HTML and the CSS and then executes some JavaScript. Deno, by following its premise of being a browser for scripts, needs a URL to run code. Let’s see it in action.

Honestly, it isn’t very different from what we’ve already done a couple of times already. As a refresher, the last time we executed our simple web server, we did the following:

Get hands-on with 1200+ tech skills courses.