Best of Deno2024

  1. 1
    Article
    Avatar of denoDeno·2y

    A Gentle Intro to TypeScript

    TypeScript enhances JavaScript by adding type annotations that catch errors during compilation, making code more robust and easier to read. Switching to TypeScript involves adding type annotations to your functions, which the TypeScript compiler uses to infer types and ensure only valid operations. This can prevent entire categories of bugs frequently encountered in JavaScript. Tools like Deno and Vite simplify TypeScript adoption by automatically handling TypeScript to JavaScript compilation.

  2. 2
    Video
    Avatar of denoDeno·1y

    Build a Real-Time WebSocket Application

    Many internet requests use HTTP, but for real-time data, WebSockets are essential. The Dino web standard API supports WebSockets to create a real-time web application. The process involves setting up a server to accept WebSocket connections and creating a client to connect and interact with this server. This guide provides a step-by-step approach to implement and test a simple WebSocket application.

  3. 3
    Article
    Avatar of denoDeno·1y

    Build a Database App with Drizzle ORM and Deno

    This tutorial guides you through setting up Drizzle ORM with Deno and PostgreSQL to manage dinosaur data. It covers installing dependencies, configuring Drizzle ORM, defining schemas, and interacting with the database using helper functions. The post concludes with suggestions for enhancing your application with complex database relationships, REST API implementation, validation, and error handling.

  4. 4
    Video
    Avatar of denoDeno·2y

    Build a JS Runtime in Rust

    Learn how to build a JavaScript runtime in Rust using Dino core and Tokyo as dependencies.

  5. 5
    Video
    Avatar of denoDeno·2y

    Deno Just Got Faster

  6. 6
    Article
    Avatar of denoDeno·1y

    Self-contained Executable Programs with Deno Compile

    Deno compile allows developers to turn JavaScript and TypeScript programs into self-contained, cross-platform binaries, eliminating the need for a runtime or dependencies. Deno 2 has introduced improvements such as support for npm packages, smaller binary sizes, and code signing. The process simplifies deployment, improves startup times, and offers enhanced security through preserveable permission flags. Examples include creating a single executable, cross-compiling for different OS, code signing, and even compiling npm packages for performance boosts.

  7. 7
    Video
    Avatar of denoDeno·1y

    Build a Database App in 3 Minutes

    Building a database application with Deno 2 and Drizzle ORM has been made easier with npm compatibility. The post guides you through installing necessary dependencies, setting up configurations, and defining schemas for a PostgreSQL database. It covers both inferring existing tables and creating new ones, and explains how to use Drizzle to manage data with TypeScript types. The tutorial concludes with performing CRUD operations on the database.

  8. 8
    Video
    Avatar of denoDeno·2y

    Programming should be simple

    Programming should be simple. Ryan Dahl, the creator of Node.js, critiques the complexity of modern Node.js setups, highlighting cumbersome processes like configuring TypeScript. He introduces Deno, a new platform that prioritizes simplicity, integrating TypeScript support out-of-the-box, providing all-in-one tooling, and ensuring security by default, while maintaining compatibility with existing npm packages.

  9. 9
    Video
    Avatar of denoDeno·2y

    Deploy a Next.js app to Deno Deploy

  10. 10
    Article
    Avatar of denoDeno·2y

    An intro to TSConfig for JavaScript Developers

    Introduction to TypeScript and configuring projects with tsconfig.json.

  11. 11
    Article
    Avatar of denoDeno·1y

    Run your Next.js SSR app on Deno Deploy

    Next.js, a powerful metaframework for building server-rendered or statically generated web applications, can now leverage Deno Deploy for server-side rendering (SSR). This guide shows you how to deploy a Next.js app with SSR on Deno Deploy, either by linking a GitHub repository or using the command line. The post also highlights new features in Deno 2.1, such as first-class Wasm support, improved package management, and long-term support.

  12. 12
    Video
    Avatar of denoDeno·2y

    Build an API server with Hono in TypeScript

  13. 13
    Article
    Avatar of denoDeno·2y

    How to document your JavaScript package

    Learn how to write comprehensive documentation for your JavaScript package using JSDoc-style comments. Discover best practices, how to provide good type information, and how to add examples to your comments.

  14. 14
    Article
    Avatar of denoDeno·2y

    How to convert CommonJS to ESM

    ECMAScript modules (ESM) are the modern standard for writing JavaScript, supporting features like async loading and better compatibility. This post guides you through updating the syntax of a legacy CommonJS project to ESM, including changes in import/export statements and package.json configurations. Removing 'use strict' and using shims for globals like __dirname and __filename are also discussed. Tools like VSCode and various npm packages can assist in the transition. Adopting ESM can alleviate compatibility issues and streamline development.

  15. 15
    Video
    Avatar of denoDeno·2y

    All-in-one tooling for JavaScript and TypeScript development

    Dino simplifies JavaScript and TypeScript development by including built-in tools for formatting, linting, and testing, saving developers time on configuration. It supports automatic code formatting, built-in linting similar to ESLint, and comprehensive testing capabilities with code coverage reporting, all without needing third-party dependencies.

  16. 16
    Video
    Avatar of denoDeno·1y

    Deploying Deno with Docker

    Deploying a Deno application with Docker is straightforward. First, ensure Docker is installed, then run the Docker commands to map ports and specify the Deno version. You can also create a Docker config file for easier setup. Once tested locally, deploy the app to a hosting provider like fly.io, which allows quick deployment by creating and launching a Docker image in the desired region.

  17. 17
    Video
    Avatar of denoDeno·1y

    Deno got even better!

    Deno 2.1 introduces several enhancements including direct WebAssembly imports, the first Long Term Support (LTS) release, improved dependency management with the 'deno outdated' command, and easier asset bundling in Deno compile. Other updates include enhanced debugging with stack traces in permission prompts and CommonJs support for legacy projects.

  18. 18
    Video
    Avatar of denoDeno·2y

    WebGPU Windowing in Deno

  19. 19
    Article
    Avatar of denoDeno·2y

    Announcing Hono on JSR

    JSR is a modern JavaScript registry that simplifies the publishing and consumption of JavaScript and TypeScript modules, supporting web standards. Over 250 new packages are published weekly. Hono, a fast and lightweight server routing framework with excellent TypeScript support, is now available on JSR. Installation can be easily done using deno or npm, and developers can benefit from integrated type definitions and documentation.