函数式工具箱:samber/lo、mo、hot 与 ro
Go 标准库至今不提供通用的 map/filter 集合操作。Go 1.18 泛型落地后,samber 系列是填补这一缺口的主要选择:lo 负责集合变换,mo 负责 Option/Result 类型,hot 负责进程内缓存,ro 负责异步事件流。四个库解决的问题互不重叠,共同特点是零依赖、泛型优先、类型安全,可单独引入,也可组合使用。
9 min read
Loading…
Quote of the day · October 26 · 关于意义 · Rick and Morty
Nobody exists on purpose. Nobody belongs anywhere. Everybody's gonna die. Come watch TV?
Notes on Agent runtimes — design decisions laid open: why it is this way, what it costs, and when it stops being true.