IMO the reset should fire regardless what happens after it.
Perhaps it makes sense for AI agents, but as a human, I will pass.
Which I don't expect from the description, and I also don't expect from the code.
---
So outside of the simple "This is broken..." feedback, I want to further pick on this example:
Don't fucking hide the imports.
Especially don't fucking hide the imports if you're showing example code, and you're doing things like
```
import { Match as M, Schema as S } from 'effect'
import { m } from 'foldkit/message'
```
Which I only know because I bothered to dig through the example playground counter (which is a different example entirely!)
It's a huge issue to show demo code where concepts magically appear, and it's just bad manners to use shorthand at the same time.
Cons: The API surface is huge so there is a steep learning curve.
The learning curve is steep tho.
In any case it's a hard technology to sell, you don't appreciate it from hello worlds. In fact you hate it for trivial programs.
It shows it's benefits at scale.
Lots of tools like T3 and opencode use it at their core because they solve non trivial problems made of queues, retries, dependency injection, schemas, etc.
I've written a vscode extension with it:
https://github.com/dearhuman/effect-decorate/blob/main/src/e...
but my experience working with elm is that things just work almost always the first time
if they can bring that over, many will take that trade off
yes somethings are harder to express, but its subjective if its a bad thing given the correctness guarantees
i haven't firmly run into the perf ceiling myself, but yes it is obviously there for more interactive apps
Especially after having used ruby and elixir extensively after years of react/Vue, it feels so backwards (and LLM unfriendly) to split front and backend unless you have gargantuan reactivity needs (you don't).
I wish JS offered just one proper server side focused frontend solution.
Similar to how Rust is obviously a better choice today than C++. Who cares if the language is “more difficult” to code in, if the agents are doing the coding. What we need is building blocks that make it harder to author bugs.
These days? Doing this FE SPA framework for Effect/typescript familiarity or Fable for F# familiarity and a model-view update pattern can help one do CQRS better, force you to think about stronger Hexagonal Architecture patterns, and overall help your application care about long term correctness more without you having to hand code every discriminated union as such.
The LLM can't replace you, but it can be an enzyme that lowers the activation energy required to switch from bad old MVC mutable tag soup to MVU frontends with strong data interface designs held in sqlite-dbs-per-aggregate (if you are of a DDD or event sourcing taste, which this pattern does not require!)