TLDR Web Dev

TLDR WEB DEV 2024-09-06

5 sections16 entrieslinks blockcomplete parse

Parse notes

  • Subscription/account footer truncated before parsefooter_truncated

01ARTICLES & TUTORIALS

OAUTH FROM FIRST PRINCIPLES

OAuth 2.0 authorization with PKCE is a standard way for third-party apps to authenticate users on websites. This article starts with a basic example of a user sharing their credentials with an app, then progressively introduces security flaws and their corresponding solutions. It breaks down each attack, explaining how it works and how the OAuth flow is improved to prevent it.

stack-auth.com10 min read

AN SSR PERFORMANCE SHOWDOWN

In benchmarks of server-side rendering (SSR) across frontend frameworks, like React, Vue, Svelte, and Solid, fastify-html and Vue are the top performers. Svelte and Solid are close behind, while React and Preact are significantly slower. As a result, Vue and Svelte provide the best balance of SSR performance and ecosystem maturity.

blog.platformatic.dev7 min read

THE COMPLETE DEVELOPER GUIDE TO REACT 19, PART 1: ASYNC HANDLING

React 19 beta introduces new hooks like useTransition and useActionState to streamline async handling, improve form management, and enable optimistic updates for smoother user experiences. These features reduce unnecessary re-renders, automate state management, and improve UI responsiveness during async operations.

callstack.com10 min read

02OPINIONS & ADVICE

TELL HN: BURNOUT IS BAD FOR YOUR BRAIN, TAKE CARE (HACKER NEWS THREAD)

This Hacker News post discusses the effects of burnout on the brain, with the original poster describing a decline in cognitive function, learning ability, and problem-solving skills. One commenter shares their personal experience of burnout and how setting boundaries and prioritizing personal well-being prevents it. Others talk about various techniques to combat it, most of which involve recognizing burnout symptoms early and addressing them before they become too much.

news.ycombinator.com

STOP USING SERIAL IN POSTGRES

PostgreSQL users should stop using the "serial" data type and switch to "identity" columns instead. There are several issues with "serial," including its lack of integrity guarantees, awkward ergonomics, and non-compliance with SQL standards. "Identity" columns, on the other hand, offer better safety, easier management, and align with SQL standards.

naiyerasif.com3 min read

WHY I STILL SELF HOST MY SERVERS (AND WHAT I'VE RECENTLY LEARNED)

This developer self-hosts a large number of services, including a 3-node Proxmox cluster and an external VPS. Self-hosting has taught him valuable lessons about complex systems, from the importance of redundant DNS to the silent failures of aging UPS batteries. In this post, he goes over some classic technologies he works with that he still finds relevant along with how to choose the right VPS providers.

chollinger.com26 min read

03LAUNCHES & TOOLS

CLAUDE MEMORY

Claude Memory is a Chrome extension that improves interactions with Claude by providing memory functionality. It allows users to store and retrieve important information from their conversations with Claude such as preferences, making interactions more personalized and context-aware.

github.comGitHub repository

REDWOOD V8.0.0

Redwood v8 (a full-stack JS framework) introduces background jobs for handling non-immediate tasks, simplifies SSR and RSC setup, and improves Storybook by switching to Vite. It also includes Docker support and updates to core packages like React, Prisma, and Vite. Breaking changes include the removal of Webpack, updates to NavLink's class handling, and recommended database structure changes for Prisma.

redwoodjs.com8 min read

QUSTAR

Qustar is a TypeScript-powered, array-like API for querying SQL databases. It offers a high-level query builder and support for PostgreSQL, SQLite, MySQL, MariaDB, and raw SQL execution.

github.comGitHub repository

04MISCELLANEOUS

WHY DON'T TECH COMPANIES PAY THEIR ENGINEERS TO STAY?

Tech companies should pay their engineers more, especially those with long tenures. Companies often fail to adequately compensate engineers for their accumulated expertise and impact, which leads to higher turnover and attrition. An impact-based compensation structure where salaries are determined by an individual's contribution to the company might be a better way to keep the best employees and pay them well.

links.tldrnewsletter.com5 min read

DEPLOYING RUST IN EXISTING FIRMWARE CODEBASES

Google has presented a practical approach to gradually introduce Rust into existing firmware codebases. The approach replaces new and high-risk code with Rust using drop-in Rust replacements for C functions. In this post, the Google team shows readers how to build Rust code in bare-metal environments, covering how to choose and port libraries, create custom targets, and integrate Rust panic handlers and allocators.

security.googleblog.com14 min read

GIVING C++ STD::REGEX A C MAKEOVER

This article shows how to wrap the C++ `std::regex` library in a clean C interface for use in C projects. This is done by creating a custom allocator that utilizes an arena-based memory management system, preventing the need for individual object deallocation and eliminating the use of `new` and `delete` within the C++ library. By doing this, the C++ regex library can be used without directly exposing its C++ objects to the C code while still benefiting from the existing functionality of `std::regex`.

nullprogram.com8 min read