tech/webdev magazine

October 22, 2024

Liskov’s Gun: The parallel evolution of React and Web Components

Tuesday, October 22, 2024 Teklinks

Because this essay is over 11 000 words long(!) I’ve made a convenience EPUB file for offline reading. (EPUB only! No PDF this time.) You can download it over on the fulfilment service I use, Lemon Squeezy, with the option to pay what you want if you feel the urge to support my writing.

Full article

Build A Static RSS Reader To Fight Your Inner FOMO

Tuesday, October 22, 2024 Teklinks

RSS is a classic technology that fetches content from websites and feeds it to anyone who subscribes to it with a URL. It’s based on XML, and we can use it to consume the feeds in our own apps. Karin Hendrikse demonstrates how to do exactly that with a static site you can use as your personal RSS reader.

Full article

Are Playwright and Vitest ready to replace Jest?

Tuesday, October 22, 2024 Teklinks

I work on these projects—mostly enterprise software, with a fair share of technical debt. I have been using the tools available at the time and following the best practices highlighted in the Guiding Principles of Testing Library. And I have mostly enjoyed testing so far.

Full article

October 21, 2024

React Folder Structure in 5 Steps

Monday, October 21, 2024 Teklinks

How to structure large React applications into folders and files is a highly opinionated topic. I struggled for a while writing about this topic, because there is no right way to do it.

Full article

October 20, 2024

October 17, 2024

How to convert CommonJS to ESM

Thursday, October 17, 2024 Teklinks

ECMAScript modules (”ESM”) are the official, modern way of writing and sharing JavaScript — it’s supported in many environments (e.g. browsers, the edge, and modern runtimes like Deno), and offers a better development experience (e.g. async loading and being able to export without globals).

Full article

October 16, 2024

Optimizing SPA load times with async chunks preloading

Wednesday, October 16, 2024 Teklinks

Hello hello! In this post, I’ll explain how to improve the performance of client-side rendered apps by avoiding the waterfall effect caused by route-based lazy-loading. We'll do this by injecting a custom script that preloads the chunks for the current route, ensuring they’re downloaded in parallel with the entry point chunk.

Full article

Google Chrome’s uBlock Origin phaseout has begun

Wednesday, October 16, 2024 Teklinks

Google Chrome has begun to phase out uBlock Origin. The developer of the free ad blocker, Raymond Hill, recently reposted a screenshot that shows Chrome automatically turning off uBlock Origin because it is “no longer supported.”

Full article

How Bun supports V8 APIs without using V8 (part 1)

Wednesday, October 16, 2024 Teklinks

When packages work in Node.js but don't work in Bun, we consider that a bug in Bun. Native C & C++ APIs are often used in the JavaScript ecosystem for performance-critical libraries like 2D Canvas, database drivers, CPU detection, and more. Bun and Node.

Full article

October 15, 2024

Liskov’s Gun: The parallel evolution of React and Web Components

Tuesday, October 15, 2024 Teklinks

Because this essay is over 11 000 words long(!) I’ve made a convenience EPUB file for offline reading. (EPUB only! No PDF this time.) You can download it over on the fulfilment service I use, Lemon Squeezy, with the option to pay what you want if you feel the urge to support my writing.

Full article

October 14, 2024

Types of React Components

Monday, October 14, 2024 Teklinks

Since React's release in 2013, various component types have emerged. Some are still essential to modern React applications, while others are mostly found in older projects (deprecated). This guide provides beginners with an overview of modern components and patterns, explaining which are still relevant and why some are no longer used.

Full article

Enhancing The New York Times Web Performance with React 18

Monday, October 14, 2024 Teklinks

As software engineers at The New York Times, we place a high value on page performance, SEO, and keeping up to date with the latest technology. With those priorities in mind, the release of React 18 stood out to us as a significant and tangible leap forward in the ever-expanding world of web development.

Full article

Self-Hosting NextJS on Fly.io Guide

Monday, October 14, 2024 Teklinks

Recently, Lee Robinson of Vercel gave a tutorial on how to self-host NextJS in a VPS. He used DigitalOcean. I also tried it in Hetzner using Ubuntu instance and it worked. The example used Docker to deploy NextJS. It has all the dependencies like Nginx and a Postgres database, also run in Docker.

Full article

October 13, 2024

A Local-First Case Study

Sunday, October 13, 2024 Teklinks

I just got back from a travel sabbatical. While the trip turned out great, the planning process was decidedly… less so. Figuring out six months of travel is a daunting task, and I quickly became dissatisfied with existing tools. True to myself, I yak shaved the problem.

Full article

October 12, 2024

OpenAI Introduces Swarm, a Framework for Building Multi-Agent Systems

Saturday, October 12, 2024 Teklinks

As the AI world is shifting towards building agentic systems, OpenAI’s team has decided to give the world an open source gift. The team has released Swarm, an open source framework for building, orchestrating and deploying multi-agent systems. Click here to check out the GitHub repository.

Full article

A New Era of Writing Code

Saturday, October 12, 2024 Teklinks

Large language models (LLM) will change how software engineers write code forever. Last weekend, I built a side project using Cursor, an LLM-based IDE, without writing a single line of code myself (I am not sponsored).

Full article

October 10, 2024

Announcing Deno 2

Thursday, October 10, 2024 Teklinks

The web is humanity’s largest software platform — building for it means potentially reaching over 5 billion people. But as web development has accelerated in recent years, it has also become increasingly and unmanageably complex. Before writing a single line of code, developers must deal with tedious configuration and wading through unnecessary boilerplate, when they would rather focus on shipping product and delivering value to users.

Full article

How we run migrations across 2,800 microservices

Thursday, October 10, 2024 Teklinks

This blog post was accurate when we published it – head to monzo.com or your Monzo app for the most up to date information. We’ve got a lot of value from our microservices architecture (2,800 and counting!), but this architecture is not without its challenges.

Full article

October 7, 2024

Serverless servers: Efficient serverless Node.js with in-function concurrency

Monday, October 07, 2024 Teklinks

We’re sharing a first look at a new version of Vercel Functions with support for in-function concurrency that brings the best of servers to serverless functions. We’ve been testing this new version with customers and are seeing a 20%-50% reduction in compute usage and respective cost reduction without latency impact.

Full article

A guide to destructuring in JavaScript

Monday, October 07, 2024 Teklinks

If you’ve spent plenty of time wading through modern JavaScript, odds are you’ve seen enough ellipses (...) to put even the most brooding 90s role-playing game protagonist to shame. I wouldn’t fault you for finding them a little confusing.

Full article

How to Minimize Latency and Cost in Distributed Systems

Monday, October 07, 2024 Teklinks

Key Takeaways Distributed Systems spanning over multiple availability zones can incur significant data transfer costs and performance bottlenecks. Organizations can reduce costs and latencies by applying zone aware routing techniques without sacrificing reliability and high availability.

Full article

October 4, 2024

The real 10x developer makes their whole team better

Friday, October 04, 2024 Teklinks

Single individuals make less of a difference to the success or failure of a technology project than you might think (and that’s a good thing). We’re all familiar with the concept of the 10x engineer or developer: “the nerdy, antisocial genius who makes groundbreaking products almost by accident,” per one description.

Full article

Rate Limiting Algorithms Explained with Code

Friday, October 04, 2024 Teklinks

Imagine you’re running an online service that has suddenly gone viral. Users from around the world are flooding your servers with requests. In this article we will dive into 5 of the most common rate limiting algorithms, their pros and cons and learn how to implement them in code.

Full article

Module Augmentation is a Hidden Gem in TypeScript

Friday, October 04, 2024 Teklinks

In my latest software development project, I encountered a challenge that led me to a hidden gem in TypeScript: module augmentation and interface merging. I was tasked with creating a feature flag package that provided each micro frontend repository with easy, type-safe access to feature flags.

Full article

October 1, 2024

How to fetch data in React

Tuesday, October 01, 2024 Teklinks

Newcomers to React often start with applications that don't need data fetching at all. Usually they are confronted with Counter, Todo or TicTacToe applications. That's good, because data fetching adds another layer of complexity to your application while taking the first steps in React.

Full article

September 27, 2024

Web Components Are Not the Future

Friday, September 27, 2024 Teklinks

A few years ago I wrote an article suggesting that Web Components might not be the most beneficial direction for Web development to head. It was a soft-handed look at where they made sense and where things fall apart. It wasn't geared as a "us against them" argument and I hoped people would come to reasonable conclusions for themselves.

Full article

Why we developed the Node.js reference architecture

Friday, September 27, 2024 Teklinks

Welcome to this new series introducing the Node.js reference architecture from Red Hat and IBM. This article is an overview of our reasons for developing the Node.js reference architecture—both what we hope the architecture will offer our developer community and what we do not intend it to do.

Full article

September 25, 2024

Vim for React Developers

Wednesday, September 25, 2024 Teklinks

Vim has been around for over 30 years, and vi (which Vim extends) almost 50 years. So why does it feel like everyone is talking about Vim right now? There’s been a Vim renaissance lately from the popularity of Neovim and its growing community.

Full article

Component Composition is great btw

Wednesday, September 25, 2024 Teklinks

When I first learned about React, I heard about all of its advantages: Virtual DOM is super fast, one-way data flow is very predictable, and JSX is ... an interesting way to put markup into JavaScript. It's easy to miss this advantage if you've always been used to it.

Full article

Compile and run C in JavaScript

Wednesday, September 25, 2024 Teklinks

From compression to cryptography to networking to the web browser you're reading this on, the world runs on C. If it's not written in C, it speaks the C ABI (C++, Rust, Zig, etc) and is available as a C library. C and the C ABI are the past, present, and future of systems programming.

Full article

September 24, 2024

Storage Disaggregated Databases and Shared Transaction Log Architecture In Comparison

Tuesday, September 24, 2024 Teklinks

There are two great papers published recently regarding database storage architecture:Understanding the Performance Implications of the Design Principles in Storage-Disaggregated Databases — Xi Pang et. al., Sigmod, June 2024 (I will call it the “LogDB” in this post, a term from the paper). Taming Consensus in the Wild (with the Shared Log Abstraction) — M. Balakrishnan, ACM SIGOPS Operating Systems Review, August 2024 (I will call it the “shared log” in this post to differentiate from the above)

Full article

September 22, 2024

Introducing TanStack Router

Sunday, September 22, 2024 Teklinks

TanStack Router is an incredibly exciting project. It’s essentially a fully-featured client-side JavaScript application framework. It provides a mature routing and navigation system with nested layouts and efficient data loading capabilities at every point in the route tree.

Full article

Your company needs Junior devs

Sunday, September 22, 2024 Teklinks

Getting coffee with a bunch of local tech leaders, I surprised myself with how stridently I argued why companies should hire junior engineers. Lately, BigTech only wants elite squads of Staff devs that can “hit the ground running” on the big (often AI) initiative.

Full article

September 19, 2024

Cleaner JavaScript promises with safe-await

Thursday, September 19, 2024 Teklinks

Nested try/catch blocks are a common pattern in JavaScript when working with promises. However, they often lead to hard-to-read and maintain code. This code is hard to read and maintain. The final return result is buried halfway through the script, making it difficult to trace error handling.

Full article

Optimising for High Latency Environments

Thursday, September 19, 2024 Teklinks

Last week, I posted a short update on LinkedIn about CrUX’s new RTT data. Go and give it a quick read—the context will help. Chrome have recently begun adding Round-Trip-Time (RTT) data to the Chrome User Experience Report (CrUX).

Full article

September 18, 2024

How Infinite Queries work

Wednesday, September 18, 2024 Teklinks

This week, a very interesting bug report was filed for Infinite Queries in React Query. It was interesting because up to this point, I firmly believed that React Query doesn't have any bugs.

Full article

Hey, this is Hono's RPC

Wednesday, September 18, 2024 Teklinks

The web framework Hono is often compared to another popular JavaScript framework, Express. Both can do similar things, but Hono has an advantage: it supports TypeScript as a first-class.

Full article

September 17, 2024