RSSAmplifier

Blog

Sandro Maglione — Newsletter and essays

The latest newsletter issues and essays from Sandro Maglione.

sandromaglione.comRSS feed ↗274 posts

Latest posts

Bringing State Machines in effect

The new @typeonce/effect-machine library is out, and it brings state machines and state charts into effect. Composable and fully type safe, just like effect. Let me give you an introduction.

The second AI coding revolution

It wasn't even a year ago when most devs stopped writing the code. The first revolution. We are now entering the second phase of AI coding: stop reading your code as well. Let me show you how.

How I am keeping up with AI

AI model releases and trends seems to be speeding up even more than before. But you don't need to follow all the details. Here is what I am focusing on to keep up with AI without being overwhelmed.

Expand your vision, not your time

With AI, you can do more than ever before. Bigger tasks in parallel. And not only in code. But more does not necessarily means more hours, that's a trap.

How much is left to implement?

AI, so fast and easy, just prompt and watch. Well, turns out it may be too easy. So easy in fact, that you can always start another project, without stopping to think if you really need it.

XState v6 Alpha

The new major version of XState (v6) is now out in alpha and ready to be tested. I already migrated a full codebase and sent 7 PRs with improvements. Let's see what's new.

AI code with loops and subagents

The new trend in AI coding is called loops. Well, in reality those are just subagents. Yes, subagents that you don't manage, but another AI does for you. And you just watch, and review.

Do you write code manually, or wait?

Writing code used to be a fully offline experience. It's writing text after all. But AI changed that as well. Without connection, do you wait, or do you write manually?

Strategies to review AI code

AI writes code fast. AI in a loop is even faster. But you are still the reviewer, are you? Here are a few ways to slow down AI to your pace, will keeping up fast mode.

Do you really understand your codebase?

AI is writing more and more of your code. You don't even need to be precise, the AI will figure out the details for you. Well, too much of this, and you stop learning. This is how I am preventing this.

How to run 20 agents at the time

Do you want to maximize your AI output? Well, you can technically run as many agents as possible, but turns out it may not be that easy, nor a successful strategy.

Do technical articles matter anymore?

I released my first post-AI article this week. Are technical articles still needed with AI? Well, yes, but not all kinds. Here is how I am thinking about this, and what I will keep reading.

Components take care of themselves

Most frontend bugs are hidden behind confused business logic and race conditions inside components. Easy solution: make all components dumb, no business logic inside them, and let AI take care of them.

Effect-ification end to end

Effect is taking over the TypeScript ecosystem, now faster than ever before. I have been running effect everywhere for a while: here is what you will get on the other side once all becomes effect.

Custom linting rules to guide AI code

AI codes fast. Too fast for you to review that much slop code and bad patterns. But there is a solution: prevent bad patterns altogether with custom linting rules. Here is how I do this.

Time off screen

I have been without my Mac for 5 days: no coding, no AI, no nothing. Out in the wild. After these 5 days, here is everything that I missed out while off screen.

The Ultimate AI coding guide

This is the last guide you need to write great code with AI. And it's nothing impressive, but mostly a series of high-level steps that, if done correctly, guarantees success with AI coding.

Get started with IndexedDb in Effect

IndexedDb in effect is finally here! A full type-safe and local-first enabled IndexedDb module is out in effect v4 beta, and it finally unlocks using IndexedDb for real. Get started here.

What makes AI write great code

Another experiment with AI this week, and this time it went extremely well. I ported Bevy (game engine) to TypeScript, with the patterns and type safety of effect. All AI. This is why it went so well.

You are the bottleneck of AI

In an attempt of going from requirements to full implementation fast with AI, this week I tried an experiment: all-in AI specs and code. Well, it failed, bad, and rather fast.

Stop AI from taking control of your code

I have been running full AI-mode on a few projects for a few weeks now. I just now paused to take a look at the overall code, and the situation is bad. Here are some ways to fix and prevent this situation.

Keep up the pace with AI

You probably cannot write code as fast as AI. But you don't have to. Even if you are not typing every word, it's still your job to ensure a working final product. And there are a few strategies you can use.

Underused XState patterns and benefits

From State of React it looks like only 10% of people used XState. I was one of those many moons ago, and after I discovered it, I never looked back. And the reasons are practical, let me tell you.

My Effect v4 beta migrations

Effect v4 beta is out. It's time to start migrating everything to it right away, of course. I already started. Here is how it went, what you should know, and what are the improvements.

Software Engineering when you have AI

AI gets better, faster, smarter, and more precise. But some hard limits (still) exist. And that's the value you bring as a Software Engineer, as you work with AI.

Effect, AI and Orchestration

My AI workflow changed (again): from a single AI running the show, to multiple AIs in parallel. I became officially a conductor of AIs, with effect acting as a guard to check the proceedings.

Intention as the seed of improvement

What's the lever that maximizes each step in your journey to mastery? It's called Intent. It removes uncertainty, increases focus, and skyrockets confidence and motivation. Let's see how.

The cycle of improvement

How does the path look like from good to better? Turns how the shape is always the same, and it repeats in cycles. But it's not linear, it's not constant, and it involves a lot of down periods.

Streaming AI with Effect

With AI, streaming is not optional anymore. But streams are complex, aren't they? Well, not really with Effect. This is how I use Effect to make AI requests with streams, parse the result, and wire all together server to client.

Effect API on Cloudflare

TypeScript API? Well, use Effect. And since Effect is just TypeScript, it just works everywhere. I have been implementing an API with Effect on Cloudflare, and it all works, great. Here is my setup.

Effect to the rescue

Many are introduced to effect for error handling and dependency injection. Those are huge wins, but effect goes way beyond that. Let me show you a couple of concrete examples.

Major releases in 2026

If 2025 was not enough, 2026 prospects are even more groundbreaking. A few major release will shake my stack once more: effect v4, xstate v6, TanStack Start, Drizzle v1.

A few Effect modules and how I use them

Effect is everywhere in my codebases, full stack, back and front and scripts and whatever. A few core module are always there, and carry most of the logic. Here they are, and how I use them.

The Dance of Precision and Speed

When should you move fast and work hard, and when should you take a step back and plan? Neither precision nor speed in isolation is the solution, each calls for the other, in a structured process.

XState at its Extreme

State management looks easy enough, until it doesn't anymore. That's why you should use XState. And if things are really complex, you will need a full actor system. Let's see how.

How to prevent AI messing with your code

The same guardrails we created for humans when writing code must be applied to AI. First check is types (Strict Type Safety), then linting, and testing as the ultimate step. A few notes.

Software Architect

When code is written mostly by AI, how do you stay relevant as a software developer? Well, you switch from pure development, to architect and engineer. This is how.

Full stack with Effect and AI

I recently deployed a full stack effect app, mostly written by AI, super fast and super type-safe. Effect is a super power, and the AI can leverage it. Here is how.

How to write maintainable code with AI

Coding with AI is becoming more and more a necessity. The new challenge is making sure the AI writes type-safe and maintainable code. Well, it's possible, here is how.

Counting time

Stop for a moment, just a short one, to understand and appreciate time. But also to notice a few rules, and to count how much does it really take to get a reward from it.

The Client stack for 2026

You can reduce all the complexity of working on the client to a few core dependencies: TanStack Router, Effect, XState. This is how I use them all, to implement everything on the client.

Effect AI SDK: A lesson in composing programs

Using AI in your app? Once again, effect comes to the rescue. I have been working with the newest Effect AI SDK, and it's a marvel of composing programs, AI providers, and AI models.

Walking your code with AI

AI is establishing solid roots in the workflow of every software developer. I am experimenting ways to write faster code with AI, without compromises on quality. Here is how.

Release fest: Effect, XState, Next, Drizzle

Some huge releases are lurking on the horizon on the end of 2025. Effect v4, XState v6, Next 16, Drizzle v1. My stack is going to evolve, this is how.

Special #100: past and future

Release number 100 of the newsletter! I started publishing every week nearly 2 years ago, every single week on Wednesday. Let's take a moment to look back, and then look forward.

Power creep and mastery

You finally unlock this new weapon in the game. Well, that felt good, for a short while. What's next? I guess the only option is a new, even stronger weapon. What about all the older ones? Power crept.

Creative power and uncertainty

Creative work is rewarding, exciting, harsh, and uncertain. When you explore the boundaries, you befriend failure, and failure is the seed for growth and success. So, why some people prefer not to choose?

A solution for your problems

How hard are your personal problems? You define the parameters, you take action. These two makes your solution, any solution. It's only a matter of reducing your action set.

Long term skills

Time pays back. For everything, always, no matter what you do. But how high is the return on investment? And for how long? Let's make time spending a conscious decision.

How to guarantee failure

In essence: You fail if you stop. But there is more. Even if you work hard and never quit, you will fail if you never adapt or chase the wrong target. Here is how to fail, or how to avoid failure.