JavaScript doesn't natively support canceling Promises. You can use `Promise.withResolvers()` to create cancelable tasks by manually resolving or rejecting Promises. Alternatively, `AbortController` can handle early rejection, which can be used for cancelable fetch requests and sequential request handling in React.
Linus Torvalds emphasizes the importance of data structures over code in software development since good data structures lead to better code design and maintainability. This author supports this view with personal experience, describing how restructuring data in a project allowed the team to move faster in the long run. This prioritization is also how Git grew to be the dominant version control system.
Product thinking is a valuable skill for engineers as it helps them understand the impact of their work and prioritize tasks properly. It's a skill that should be added to an engineer's “talent stack” to help them become well-rounded engineers.
Sometimes incompetent management can actually offer advantages in terms of resource allocation and project autonomy. In poorly run companies, the lack of clear objectives and performance evaluations can let employees pursue their own goals. Conversely, well-run companies with strict performance metrics and resource management inadvertently stifle such initiatives, as employees prioritize meeting pre-set targets over exploration.
Termino.js is a lightweight JavaScript library for creating customizable web-based terminal interfaces. It supports inputs and custom functions and has an HTML integration.
Pongo provides a NoSQL-like interface by treating PostgreSQL as a document database benefiting from JSONB support.
QuickJS is a TypeScript package that allows you to safely execute JavaScript code within a WebAssembly sandbox using the QuickJS engine. It's great for isolating and running untrusted code securely.
There has been a resurgence of high-quality systems programming meetups in 2024, such as the Munich Database Meetup and NYC Systems meetup. Pre-pandemic meetups were often only product-focused, while these new meetups are more technical in nature. While meetups are a lot of work to organize properly, there is a growing interest in in-depth technical discussions within the systems programming community.
To refine thinking through writing, start by making definite claims and avoid ambiguity. Then, unfold your ideas by exploring the reasoning behind them, even if it means revealing your ignorance. Look for counterexamples to challenge your claims, either locally to improve your explanation or globally to replace your entire mental model.
2024.07.08·links.tldrnewsletter.com·15 min read·TLDR Web Dev Apple is focusing on extending device longevity and using AI and software innovations like Apple Intelligence to drive customer upgrades and new revenue streams amidst slower hardware innovation. This strategy aims to shift the company's growth focus from hardware sales alone to more sustainable software-driven services (which also have the benefit of being subscription-based).
Saturn is a Jupyter Notebook client for Mac.
Amazon is discontinuing its Astro for Business robot after less than a year, issuing refunds and focusing on the still-unreleased home version, which may incorporate generative AI features.
A public domain wireless geolocation database.
An open-source Python app development framework.
Next.js needed a new bundler due to the limitations of Webpack in handling large-scale applications, particularly with the increasing use of component libraries and the rise of computationally heavy applications. The new bundler, Turbopack, aims to provide faster HMR and initial compile times, maintain compatibility with existing applications, and scale effectively for large codebases. It will also incorporate persistent caching and production optimizations.
The New York Times upgraded its React version, which brought some unexpected challenges. The upgrade required solving challenges with existing embedded interactives and managing script loading order. However, the result of the upgrade was immediately better performance. For example, its INP scores in the p75 range dropped by roughly 30% across the entire site.
Container queries are a new CSS feature for responsive layouts. The feature isn't supported by every browser. This article offers a fallback strategy using JavaScript and a custom `responsive-container` element that enables container queries while supporting older browsers.
This author regrets not shipping his app earlier, after discovering a competitor had launched a similar product with more features and a larger user base. He had delayed launching his app for two years due to perceived flaws, but realized that shipping, even with imperfections, is much better than not shipping at all. The author ultimately became a paying customer of the competitor's app and believes in shipping products early to gain traction and user feedback.
The claim that learning C teaches you "how computers work" is inaccurate because C operates within its own abstract machine, not directly on the hardware. However, learning C can provide great insights into computer architecture and operating systems, as the C abstract machine closely maps to these elements. For programmers primarily using higher-level languages, learning C can be valuable to understanding how their code interacts with the underlying machine.
This author analyzed 10,000+ comments on Hacker News' "Ask HN: Who Is Hiring" threads using GPT-4o and LangChain to understand current job market trends. They found that remote work remains popular, visa sponsorship is still competitive, and there's a growing demand for experienced (8+ years of experience) developers.
LetsForm makes React form development easier with JSON schemas and native UI components (Material UI, Ant Design, etc.). It eliminates boilerplate code, offers visual design tools, and provides features like validation, dynamic forms, and pre-built templates.
Browspilot is a Chrome extension that provides full-text search of your browsing history.
Boring UI takes in a JSON object and a prompt, then generates a UI for it.
.DS_Store, which stands for "Desktop Services Store," was originally created to store metadata like icon positions and folder settings for the Mac OS X Finder. The name was chosen because there were plans to make the Finder backend a public API called Desktop Services. However, due to a bug, .DS_Store files are now excessively created even when users don't change view settings. The Desktop Services API was never fully released.
The AI industry is facing a $600 billion question about revenue generation, despite huge investments in AI infrastructure. While the GPU supply shortage has eased and stockpiles are growing, OpenAI still dominates AI revenue. Although AI is predicted to be a transformative technology, there are still tons of problems to work through, like its lack of pricing power, investment wastage, and rapid semiconductor depreciation.
Dovetail is a customer insights platform that grew through focusing on small improvements, identifying under-served customer segments, and expanding their marketing channels strategically. It integrates with existing tools and uses AI strategically. Dovetail was developed with a design-led approach.
Jeffrey Snover, the architect behind PowerShell, overcame resistance within Microsoft's culture to create PowerShell, which transformed Windows system administration.
To fight distractions, software developers should have “do-nothing” days for routine tasks and "flow days" for peak productivity.
This author presents an optimized matrix multiplication implementation in C that follows the BLIS design which outperforms NumPy's OpenBLAS implementation on an AMD Ryzen 7700 processor by efficiently utilizing SIMD instructions and multi-threading.
GitHub searches and shows the entire corpus of users when adding a user to a repository.
This guide explores profiling techniques to pinpoint high CPU usage in Node.js applications. It covers using built-in profilers, Chrome DevTools, the Node Inspector API, and the perf tool. The guide also mentions continuous profiling for ongoing monitoring and explores memory leak detection.
A poor Largest Contentful Paint (LCP) score can often be caused by backend issues. While tools like Page Speed Insights and Google Lighthouse are helpful for frontend analysis, tracing user journeys and examining spans help uncover more issues. By doing so, developers can pinpoint problematic database queries or other backend operations that contribute to slow LCP scores.
Teams should focus on fewer tasks and allow for more downtime, which counterintuitively leads to faster feature delivery and increased value. When working on too many things at once, teams may actually deliver things slower because there are too many things that are in a work-in-progress state. Smaller, faster completions keep momentum going.
This author switched teams to AI/ML Training Infra due to the fast growth and opportunities in the AI space. They were also motivated by curiosity about the technical challenges in AI compute efficiency and the opportunity to work with talented engineers.
json.bash is a command-line tool and bash library that creates JSON.
fast-json-stringify is a library that converts JavaScript objects to JSON strings. It's faster than JSON.stringify, especially for small payloads.
A collection of Vue tools that help make development easier. This includes a type-check command line tool, TypeScript plugins, VSCode extensions, and more.
Property-based testing is a technique that originated from academic research. It has seen widespread adoption in various programming languages. However, most current libraries lack advanced features like stateful and parallel testing, which were established as state-of-the-art fifteen years ago. This lack of progress is due to the perception that pure function testing is more valuable, the need for specialized training for stateful modeling, and the success of closed-source solutions in industry adoption.
Choosing the right embedding model for search and RAG applications requires considering your specific needs and evaluating different models on your own data. The MTEB Leaderboard is a helpful starting point, but validation on your own use case is necessary for the best results.
Canva's experimentation analysis platform started with a data scientist-focused Python package and a command-line interface. It then transitioned to an interface that could be used by all employees and a separate microservice for analysis components. This allowed it to manage experiments much easier in-house.
Lots of people have pivoted into AI/ML development by doing courses on the side, transitioning within their company, and/or getting into data engineering.
One million particles rendered with the GPGPU technique using WebGL, with source code and explanations provided.
Palico AI is an LLM development framework for fast iteration.
Projects fail due to resource scarcity, multitasking, and siloed teams.
Optimizing JavaScript code for performance often involves trade-offs with readability. Careful benchmarking is necessary to identify bottlenecks and measure improvements. Common optimization techniques include avoiding string comparisons and different object shapes, minimizing the use of array and object methods, reducing indirection, and optimizing memory access patterns. Using eval() strategically and understanding the nuances of string manipulation can lead to better performance.
React Server Components (RSC) are primarily server-side components that optimize performance by fetching data and rendering on the server, while Client Components handle interactivity and state management on the client side. In the RSC paradigm, Server Components are the default, and Client Components are explicitly marked using 'use client'. While Server Components cannot be directly nested within Client Components, they can be passed as props to Client Components.
Million.js is a minimalistic JavaScript compiler that improves React's performance by reducing memory usage and enhancing rendering speed through a granular approach to DOM updates. It uses optimized higher-order components called blocks to achieve these performance gains.
Mocking in tests, particularly for IO operations, can lead to a false sense of security as it often fails to cover edge cases and failure modes of the real service. Instead of relying on mocks, developers should prioritize thorough unit testing and use alternatives like in-memory databases or virtual file systems for simpler IO testing.
FreeDOS, an open source version of DOS, is turning 30 years old. The project was started in 1994 by Jim Hall, who wanted to preserve the command line experience after Microsoft stopped developing DOS. Over the years, FreeDOS has thrived due to its strong community. To keep the project going, the FreeDOS team maintains a website, shares updates on social media, and actively solicits contributions from developers.
Networking offers opportunities for advice, mentorship, and job prospects. To cold contact someone, you should create thoughtful, respectful messages via email or LinkedIn. Also, try to utilize your alumni networks and/or personal connections if possible.