- read

Fast, Secure, Simple: Getting Started with Deno and Oak

Rico Fritzsche 44

Photo by Hannah Pemberton on Unsplash

A few weeks ago, my colleague Ralf Westphal caught my interest in Deno. He told me how it effortlessly supports TypeScript without any need for a separate build step or extra settings. This seemed promising. Given that I’m shifting my career towards building fast and effective Micro SaaS solutions and MVPs, Deno seemed like the right tool to explore.

Why does this matter? Micro SaaS solutions and MVPs thrive on speed, flexibility, and security, which are all attributes that Deno promises to deliver. But let’s not get ahead of ourselves; this is a hands-on introduction to Deno.

What Exactly Is Deno?

Don’t mistake Deno for just another NodeJS Framework. In fact, it’s a whole new JavaScript and TypeScript runtime, built on the V8 JavaScript engine. Created by the same genius behind NodeJS, Ryan Dahl, Deno is written in Rust and aims to boost your productivity.

Key Features

  • TypeScript Support: You get it right out of the box, no fuss.
  • ES Module Compatibility: Fully supported, right from the start.
  • Package Management: Forget about the crappy NPM. With Deno, packages are imported directly from URLs and are cached on your hard drive for future use.

Security First

One standout feature is Deno’s focus on security. Unlike Node, Deno runs your code in a secure sandbox, restricting access to the file system, network, and more. You can grant specific permissions using flags like --allow-net and --allow-env. I'll go deeper into security aspects in a future article.

Seamless Deployments

Deno allows for simple deployments, fully integrated with GitHub. A superb way to get your ideas out there, fast.

Getting Started: Setting Up Your Local Machine

Before you can get started, you need to install Deno on your computer. If you’re using a Mac, it’s as simple as running the following command with Homebrew: