TLDR Web Dev

TLDR WEB DEV 2024-05-16

5 sections15 entrieslinks blockcomplete parse

Parse notes

  • Subscription/account footer truncated before parsefooter_truncated

01ARTICLES & TUTORIALS

BUILD YOUR OWN REACT.JS IN 400 LINES OF CODE

This article explains how to build a simplified version of React with 400 lines of code. The simplified React utilizes Fiber architecture and concurrency mode to avoid blocking the main thread during rendering. It is able to execute tasks during browser idle time. It uses a linked list structure to connect work units and triggers updates through a custom useState implementation.

webdeveloper.beehiiv.com6 min read

HOW FACEBOOK SERVED BILLIONS OF REQUESTS PER SECOND USING MEMCACHED

Facebook used Memcached, a key-value store, to efficiently handle billions of requests per second. It achieved this by scaling Memcached at three levels: cluster, region, and worldwide. It used parallel requests and batching, optimized client-server communication, and managed congestion effectively to reduce latency. “Memcache pools” were used to reduce load on their databases.

read.engineerscodex.com8 min read

MAKING A POSTGRES QUERY 1,000 TIMES FASTER

This developer discovered a significant performance issue in a database query used for indexing posts in their application Mattermost. The query was initially slow due to too much filtering, but was sped up by using PostgreSQL's row constructor comparisons. To help find this speed boost, the developer used the BUFFERS option in EXPLAIN statements for detailed insights and prioritized Index Cond over Filter for efficient queries.

mattermost.com18 min read

02OPINIONS & ADVICE

YOU PROBABLY DON'T NEED MICROSERVICES

Microservices are popular and great for scalability and team organization, but can bring problems to smaller organizations. Too many services can be hard to maintain, create excessive interdependencies, and make downsizing difficult in tough economic times.

thrownewexception.com7 min read

HOW NOT TO DO CODE REVIEWS

Traditional code reviews, which focus on manually finding errors, have become a bottleneck for engineering teams. With advancements in automated testing and static code analyzers, code reviews can now shift their focus from error-finding to knowledge sharing and long-term codebase health.

aviator.co9 min read

I CODED SOMETHING DUMB AND I'M PROUD OF IT

This developer added a quicksort animation feature to a game to visually sort items while handling potential changes in the list being sorted. Instead of optimizing the quicksort algorithm to resume from its last state, the developer chose a simpler, inefficient solution (on purpose): the sorting illusion is created by repeatedly running the algorithm from the start until a change occurs.

plbrault.com5 min read

03LAUNCHES & TOOLS

BETTER SSE

Server-sent events is a protocol that allows web servers to push data to clients without the need for alternative mechanisms such as pinging, long-polling, or WebSockets. Better SSE is a dependency-less server-sent events implementation for Node, written in TypeScript.

github.comGitHub repository

GLANCE

Glance is a self-hosted dashboard that puts all your feeds in one place, such as RSS feeds, subreddit posts, weather, bookmarks, stocks, YouTube videos, GitHub releases, and more.

github.comGitHub repository

QUARY

Quary is an open-source business intelligence tool for engineers. Engineers can use it to connect to their database, write SQL queries, create charts/dashboards/reports, and more.

github.comGitHub repository

04MISCELLANEOUS

HOW I MADE MY GITHUB PROFILE README DYNAMIC

You can add a README to your profile repository by naming it the same as your GitHub username. GitHub Actions can be used to integrate dynamic content such as real-time statistics and latest blog posts using tools like `github-readme-stats` and `metrics`.

tduyng.github.io6 min read

THE CARCINIZATION OF WEB FRAMEWORKS

JavaScript frameworks have evolved and converged towards a common set of features, such as immutability for developer experience and code stability, single-directional data flow for simplified state management, signals for granular reactivity, and server-side rendering (SSR) for improved SEO and performance.

toddledev.medium.com7 min read