Backend
Deno
A secure JavaScript and TypeScript runtime from the creator of Node.js, with built-in tooling.
What it is
Deno was created by Ryan Dahl, the author of Node.js, to fix what he saw as design mistakes. The runtime is written in Rust and uses V8.
TypeScript works out of the box with no separate build step. A formatter, linter, test runner and dependency manager are built in.
By default a script has no access to files, network or environment variables: you grant them with --allow-* flags. Modern versions also support package.json and npm packages.
Use it when
- Scripts and small services in TypeScript with no build setup.
- You need a permission model for running third-party code.
- Edge functions: Deno powers Deno Deploy and Supabase Edge Functions.
Avoid it when
- A large existing Node project with native modules: migration costs more than it gives.
- Your team depends on tools that only support Node.
Key concepts
- Permissions
- Explicit permissions for files, network and env through run flags.
- Web-стандарти
fetch,Request,Responseand Web Streams are available globally.- JSR
- A package registry for TypeScript that works across runtimes.
- deno.json
- The config file: tasks, imports, TS settings.
Example
Interview questions
1. How does Deno differ from Node.js?
Deno has built-in TypeScript, tooling and a permission model, while Node needs separate packages for these. Both run on V8, and Deno's npm compatibility is now high.
2. What are the
--allow-*flags for?They limit what code can do: read files, use the network, read env. A compromised dependency cannot read your keys without permission.
3. What is Deno Deploy?
It hosts Deno code on edge nodes, running close to the user. It suits lightweight APIs and functions.
Related technologies
- Node.jsA server-side JavaScript runtime built on the V8 engine with an event-driven, non-blocking I/O model.
- BunA fast JavaScript and TypeScript runtime that bundles a runtime, package manager, bundler and test runner.
- TypeScriptA superset of JavaScript with static types that compiles to plain JS.
- Cloudflare WorkersA serverless platform on Cloudflare's edge: V8 isolate code starts almost instantly worldwide.
Logos belong to their owners and are used for identification only. Icons: Simple Icons (CC0), Devicon (MIT).