Sign in

nyaomaru

@nyaomaru-dev.bsky.social
94 followers 205 following 186 posts

Funny frontend engineer (React / Vue / TypeScript) Creator of is-kit 😺 is-kit.dev/en DSA View View 👀👀 github.com/nyaomaru/dsa-view-view

PostsRepliesMedia
nyaomaru @nyaomaru-dev.bsky.social · 8h
For a library, the source code isn’t the final artifact. The packed npm package is. That became very obvious during my tsup → tsdown migration, so I tested the actual tarball in temporary ESM, CJS, and TypeScript consumers. Full write-up tomorrow. 🔧 #TypeScript #OpenSource
020
nyaomaru @nyaomaru-dev.bsky.social · 19h
Yeah, they look super weird at first 😹 .d.mts and .d.cts are basically declaration-file versions of .mts / .cts, so the module format is explicit. It makes sense technically, it just didn’t match the filenames my package had already published. 😸
000
nyaomaru @nyaomaru-dev.bsky.social · 05/10/2026
A small tsup → tsdown migration surprise. Before: index.mjs index.js index.d.ts First tsdown build: index.mjs index.cjs index.d.mts index.d.cts The build passed. Nothing was “wrong” with tsdown, but reasonable new defaults can still break an existing package contract. 👀 #TypeScript #OpenSource
130
nyaomaru @nyaomaru-dev.bsky.social · 04/10/2026
What if AI didn’t write the “Why” in a CHANGELOG at all? In changelog-bot v0.7.0, Jev can select rationale already present in the PR description instead of generating new prose. Less invention. More grounding. Still experimental, but I like the direction. 👀 #OpenSource #AI #DevTools
010
nyaomaru @nyaomaru-dev.bsky.social · 03/10/2026
A green build doesn’t always mean a safe release. 👀 I migrated a real TypeScript OSS library from tsup to tsdown. The config change was tiny. The build passed. But the generated package no longer matched its existing contract. Full write-up Wednesday. 🔧 #TypeScript #OpenSource #tsdown
120
nyaomaru @nyaomaru-dev.bsky.social · 02/10/2026
Yes, I test the parent failure path separately. In fact, one test verifies that when the outer parent guard fails, refineKey doesn’t even read the child property. The parent establishes the shape first, then the child refinement runs inside that boundary. 😸
100
nyaomaru @nyaomaru-dev.bsky.social · 02/10/2026
changelog-bot v0.7.0 🚀 Experimental TypeSafe Jev support for WHY extraction is here. It selects rationale in PR descriptions instead of generating prose. Huge thanks to github.com/johnnylemonny! 🙌 github.com/nyaomaru/cha... #OpenSource #TypeScript #CHANGELOG #DevTools
github.com
Release v0.7.0 · nyaomaru/changelog-bot
What's new 🚀 v0.7.0 introduces experimental TypeSafe Jev support for WHY extraction. Jev is an opt-in WHY-only engine that performs confidence-aware candidate selection instead of generating new pr...
040
nyaomaru @nyaomaru-dev.bsky.social · 02/10/2026
Exactly! The child expression can be narrowed, but that doesn’t remove the uncertainty from the surrounding Node. That’s why the `isX` checks still matter for codemods when the API remains open. 😸
100
nyaomaru @nyaomaru-dev.bsky.social · 01/10/2026
Reusable AST guards can lose child-property narrowing. With is-kit, I compose existing ts.isX guards with a generic refineKey() helper while preserving parent + child narrowing. 🔧 dev.to/nyaomaru/typ...
dev.to
TypeScript Compiler API: Preserving Child Node Narrowing in Reusable Type Guards 🔧
Hoi hoi! 👋 I'm @nyaomaru, a frontend engineer exploring new possibilities with Jev 😸 (I'm also...
030
nyaomaru @nyaomaru-dev.bsky.social · 30/09/2026
I wrote new article! 🔧 Reusable parent + child narrowing gets awkward in the TypeScript Compiler API. I explored property refinement with `is-kit` and what changes in TypeScript 7. dev.to/nyaomaru/typ... #TypeScript #OpenSource
dev.to
TypeScript Compiler API: Preserving Child Node Narrowing in Reusable Type Guards 🔧
Hoi hoi! 👋 I'm @nyaomaru, a frontend engineer exploring new possibilities with Jev 😸 (I'm also...
030
nyaomaru @nyaomaru-dev.bsky.social · 30/09/2026
Yeah, that makes sense 😹 A giant closed union for every AST node would probably be expensive for the checker.
001
nyaomaru @nyaomaru-dev.bsky.social · 30/09/2026
Exactly 😹 This is a perfect example of where “automatic narrowing” still stops short. If node.kind doesn’t narrow the parent Node itself, codemod authors are still reaching for isX guards for another round.
100
nyaomaru @nyaomaru-dev.bsky.social · 29/09/2026
TypeScript 7 changed the Compiler API surface, but one thing surprised me: a broad `ast.Node` still isn’t a closed discriminated union. So `kind === CallExpression` doesn’t replace `isX` narrowing for that input. Full write-up tomorrow. 🔧 #TypeScript #CompilerAPI
250
nyaomaru @nyaomaru-dev.bsky.social · 29/09/2026
🎉 Changelog Bot is now live in GitBot’s in-app Library! You can now discover and use @nyaomaru/changelog-bot directly from GitBot 😸 Huge thanks to Sahil and the GitBot team for adding it! gitbot.codeongrass.com/bots/changelog-bot #OpenSource #DevTools
gitbot.codeongrass.com
Changelog Bot · GitBot Library
Previews release changelogs before updating the configured changelog.
020
nyaomaru @nyaomaru-dev.bsky.social · 28/09/2026
What does `arguments[0]` actually prove? Nothing, if the array is empty. A reusable guard for the first argument needs to prove: 1. index 0 exists 2. the value matches 3. the parent type remembers both facts Tiny runtime check, surprisingly interesting type problem. #TypeScript
030
nyaomaru @nyaomaru-dev.bsky.social · 27/09/2026
is-kit v1.15.0 is out! 🚀 A discussion about type-guard drift led to `discriminatedUnion`. It checks union coverage at compile time, so missing, extra, or mismatched branches can’t silently slip through. 👀 github.com/nyaomaru/is-... #TypeScript #OpenSource #is-kit
github.com
Release v1.15.0 · nyaomaru/is-kit
What's new 🚀 Exhaustively validate discriminated unions discriminatedUnion creates one type guard from a finite discriminated union. It requires every discriminant value in both the values tuple an...
020
nyaomaru @nyaomaru-dev.bsky.social · 27/09/2026
Optional AST children hide a different problem. `initializer?: Expression` isn’t just “another property to narrow.” A reusable guard must first prove that the property exists, then refine its value. That runtime contract deserves to be explicit. #TypeScript #OpenSource
020
nyaomaru @nyaomaru-dev.bsky.social · 26/09/2026
TypeScript 5.5 added inferred type predicates, which is great. But a compound check like: `CallExpression → expression → Identifier` can still end up as plain `boolean` when extracted. So where exactly does reusable narrowing stop being “free”? 👀 #TypeScript
020
nyaomaru @nyaomaru-dev.bsky.social · 25/09/2026
A type guard can prove both the parent and a child property at runtime. But if you extract the check into a reusable function, does TypeScript preserve both facts? `CallExpression → expression → Identifier` That small question turned into a bigger TypeScript rabbit hole. 😸 #TypeScript #WebDev
030
nyaomaru @nyaomaru-dev.bsky.social · 24/09/2026
A thought from writing this article 😸 A stale type guard can accept bad data, and the bug may appear much later far from the boundary that let it through. 👀 That distance is what makes silent drift painful. dev.to/nyaomaru/you... #TypeScript #OpenSource #OSS
dev.to
Your Type Guard Can Silently Drift from Your TypeScript Type 🔧
Hoi hoi! 👋 I'm @nyaomaru, a frontend engineer just back from a short vacation on Texel, a small...
030
nyaomaru @nyaomaru-dev.bsky.social · 23/09/2026
TypeScript article! 🔧 A handwritten type guard can stay valid while runtime checks fall behind the type. Why this drift happens, and how `typedStruct<User>()` catches it. 👀 dev.to/nyaomaru/you... #TypeScript #OpenSource
dev.to
Your Type Guard Can Silently Drift from Your TypeScript Type 🔧
Hoi hoi! 👋 I'm @nyaomaru, a frontend engineer just back from a short vacation on Texel, a small...
030
nyaomaru @nyaomaru-dev.bsky.social · 22/09/2026
This week I’ve been sharing one TypeScript maintenance problem: A hand-written type guard can keep compiling even after the type it claims to validate has changed. Tomorrow I’ll publish the full write-up — including drift, optional fields, nested types, and where `typedStruct` fits. 🔧 #TypeScript
010
nyaomaru @nyaomaru-dev.bsky.social · 21/09/2026
A small runtime-validation detail I like nickname?: string | null actually contains two separate contracts. The key may be absent. And if it exists, the value may be `null`. That’s why I prefer keeping key-level optionality and value-level nullability explicit. 👀 #TypeScript #OpenSource
050
nyaomaru @nyaomaru-dev.bsky.social · 20/09/2026
What if the existing TypeScript type could act as a compile-time contract for your runtime guard? That’s what I wanted from `typedStruct<User>()`. The runtime checks are still explicit, but missing or incompatible fields become TypeScript errors instead of silent drift. 👀 #TypeScript #OpenSource
030
nyaomaru @nyaomaru-dev.bsky.social · 19/09/2026
Yesterday I mentioned that `value is User` is a promise, not proof. Here’s the maintenance bug that follows: Add a field to `User`, forget to update the hand-written guard, and TypeScript can still compile. 👀 The type evolved. The runtime validation quietly stayed behind. #TypeScript
010
nyaomaru @nyaomaru-dev.bsky.social · 18/09/2026
TypeScript type guard finding 👀 A return type like: `value is User` is a promise made by the function — not proof that the runtime implementation actually checks every field. That gap can quietly become a maintenance problem. #TypeScript #JavaScript
010
nyaomaru @nyaomaru-dev.bsky.social · 17/09/2026
There’s a TypeScript side to `filter(Boolean)` too. 👀 It removes falsy values at runtime, but `Boolean` isn’t a type guard. So TypeScript doesn’t generally know that `null` and `undefined` are gone. More in my latest article 👇 dev.to/nyaomaru/why... #TypeScript #JavaScript #OpenSource
030
nyaomaru @nyaomaru-dev.bsky.social · 16/09/2026
`filter(Boolean)` looks nice — until `0`, `false`, or `""` quietly disappears. 🙀 Falsy ≠ Nullish. I wrote about TypeScript narrowing, `isNotNil`, and ESLint. 😸🔧 dev.to/nyaomaru/why... #TypeScript #JavaScript #OpenSource
dev.to
Why filter(Boolean) Is Not a Nullish Filter in TypeScript 🔧
Hoi hoi! 👋 I'm @nyaomaru, a frontend engineer building small TypeScript OSS with shoyu ramen....
030
nyaomaru @nyaomaru-dev.bsky.social · 15/09/2026
Thx! 😸
000
nyaomaru @nyaomaru-dev.bsky.social · 15/09/2026
My post was featured in DEV Community’s Top 7 Posts of the Week! 😸🎉 Really happy to see it picked up by the DEV team. Thanks to everyone who read, reacted, and commented! ❤️‍🔥 dev.to/devteam/top-...
dev.to
Top 7 Featured DEV Posts of the Week
Welcome to this week's Top 7, where the DEV editorial team handpicks their favorite posts from the...
110
nyaomaru @nyaomaru-dev.bsky.social · 14/09/2026
Tiny JavaScript edge case 👀 `value != null` is often used as a short nullish check. But `document.all` is a historical browser exception: it behaves as nullish under loose equality. JavaScript is fun. 😹 #JavaScript #WebDev
000
nyaomaru @nyaomaru-dev.bsky.social · 13/09/2026
I don’t think every small check needs a library. 😸 For a one-off nullish filter, an inline type predicate is perfectly fine. A named guard becomes more useful when the same meaning starts showing up repeatedly across the codebase. github.com/nyaomaru/is-... #TypeScript #OpenSource
github.com
GitHub - nyaomaru/is-kit: Build small guards. Compose them. Lightweight, zero-dependency TypeScript type guards for runtime validation and natural narrowing. Runtime-safe 🛡️, composable 🧩, and ergonom...
Build small guards. Compose them. Lightweight, zero-dependency TypeScript type guards for runtime validation and natural narrowing. Runtime-safe 🛡️, composable 🧩, and ergonomic ✨. - nyaomaru/is-kit
030
nyaomaru @nyaomaru-dev.bsky.social · 12/09/2026
There’s a TypeScript side to `filter(Boolean)` too. 👀 It removes falsy values at runtime, but `Boolean` itself isn’t a type guard. So TypeScript doesn’t generally narrow away `null` and `undefined` just because the runtime filter does. #TypeScript
010
nyaomaru @nyaomaru-dev.bsky.social · 11/09/2026
Small JavaScript reminder 👀 `filter(Boolean)` means “keep truthy values,” not “remove only null and undefined.” So valid values like `0`, `false`, and `""` disappear too. Falsy and missing are different requirements. #JavaScript #TypeScript
040
nyaomaru @nyaomaru-dev.bsky.social · 10/09/2026
One thing I noticed while learning DSA: Very different algorithms can be difficult for the same reason, too much changing state to keep in your head. 👀 🌧️ Two pointers moving 🔢 Data changing from Map → buckets 👉 A sorted area growing step by step dev.to/nyaomaru/lea... #DSA #OpenSource
dev.to
Learn Trapping Rain Water, Top K Frequent and Selection Sort with Step-by-Step Visualization in DSA View View 👀👀
Hoi hoi! I’m @nyaomaru, a frontend engineer who has been obsessed with ramen lately. 😸🍜 Have you...
020
nyaomaru @nyaomaru-dev.bsky.social · 09/09/2026
New DSA View View article! 👀👀 🌧️ Trapping Rain Water → Two Pointers 🔢 Top K Frequent → Buckets 👉 Selection Sort → Selection Watch the runtime state change step by step. 😸 dev.to/nyaomaru/lea... #DSA #TypeScript #OpenSource
dev.to
Learn Trapping Rain Water, Top K Frequent and Selection Sort with Step-by-Step Visualization in DSA View View 👀👀
Hoi hoi! I’m @nyaomaru, a frontend engineer who has been obsessed with ramen lately. 😸🍜 Have you...
030
nyaomaru @nyaomaru-dev.bsky.social · 08/09/2026
is-kit v1.14.1 is out 😸 This release fixes two non-obvious runtime paths • preserves strict nullish semantics in browsers, including the document.all edge case • removes exception-driven checks from the successful isTypedArray path github.com/nyaomaru/is-... #TypeScript #OpenSource
github.com
Release v1.14.1 · nyaomaru/is-kit
What's Changed docs(changelog): 1.14.0 by @github-actions[bot] in #288 docs: validate hey-api types by @nyaomaru in #289 docs: clarify TypeScript 7 Compiler API compatibility by @nyaomaru in #290 ...
130
nyaomaru @nyaomaru-dev.bsky.social · 07/09/2026
I thought I’d found a TypeScript Compiler API gap. Then I reproduced it with plain objects. 👀 Turns out it’s a generic property-refinement composition problem. is-kit preserves the checked parent + child refinement for reuse without a manual return annotation. #TypeScript #OpenSource
050
nyaomaru @nyaomaru-dev.bsky.social · 06/09/2026
TypeScript inference finding 👀 Inline checks narrow correctly, but extracted predicates can fall back to `=> boolean`, losing child refinement on reuse. is-kit keeps it with `and()` + `refineKey()`. #TypeScript #OpenSource #CleanCode #TypeGuard
040
nyaomaru @nyaomaru-dev.bsky.social · 05/09/2026
TS7 AST finding 👀 Tested on TS 7.0.2 + a pinned 7.1 nightly: The shipped broad `Node` / `Expression` types still don’t narrow as discriminated unions through direct `kind` checks. is-kit keeps a reusable parent-child guard typed, without a manual parent intersection. #TypeScript #OpenSource
030
nyaomaru @nyaomaru-dev.bsky.social · 05/09/2026
Exactly! I see schema libraries and type guards as solving different problems. 😸 If a type guard is enough, I don’t think there’s any need to reach for a schema library.
000
nyaomaru @nyaomaru-dev.bsky.social · 04/09/2026
Small guards are great for reusable boolean validation. Choose a schema library when you need rich errors, coercion, defaults, transforms, or code generation. is-kit.dev/guides/valid... #TypeScript #OpenSource #CleanCode
is-kit.dev
Validate unknown in TypeScript Without a Schema Library | is-kit
Validate unknown TypeScript values with small composable type guards and safeParse, without adopting a schema-first validation workflow.
130
nyaomaru @nyaomaru-dev.bsky.social · 03/09/2026
Number of Islands clicked when I stopped thinking “recursion”. Find land → paint connected land away → repeat. 🏝️👀 Visualized step by step: dev.to/nyaomaru/lea... #DSA #TypeScript #OpenSource
dev.to
Learn Number of Islands, Invert Binary Tree, and Course Schedule with Step-by-Step Visualization in DSA View View 👀👀
Hoi hoi! I’m @nyaomaru, a frontend engineer who is surprised by how cold it is in the Netherlands...
030
nyaomaru @nyaomaru-dev.bsky.social · 03/09/2026
Thank you so much for all the kind words!! 😺✨ Your message really encouraged me, and it made me very happy! I’ll keep creating, coding, and sharing every day. 😸 Let’s keep going and do our best together! 💪
010
nyaomaru @nyaomaru-dev.bsky.social · 02/09/2026
Thank you! 😺 Actually, almost all of the pixel art is hand-drawn! 👀✨ I'm really happy you like the green and the cats too! 🐱💚
010
nyaomaru @nyaomaru-dev.bsky.social · 02/09/2026
I published another DSA View View article! 😸👀 This time: 🏝️ Number of Islands → DFS 🌳 Invert Binary Tree → Recursion 📚 Course Schedule → Topological Sorting The final code can be short, but the changing state is not always easy to follow. Let’s view it! 👀 dev.to/nyaomaru/lea... #DSA #OpenSource
dev.to
Learn Number of Islands, Invert Binary Tree, and Course Schedule with Step-by-Step Visualization in DSA View View 👀👀
Hoi hoi! I’m @nyaomaru, a frontend engineer who is surprised by how cold it is in the Netherlands...
130
nyaomaru @nyaomaru-dev.bsky.social · 02/09/2026
This gives me a much better direction for the next round of research. I really appreciate you taking the time to share all of this, it genuinely makes me happy to get this kind of feedback! 😸🙏
010
nyaomaru @nyaomaru-dev.bsky.social · 02/09/2026
Before deciding how is-kit should fit into that world, I’m going to take a closer look at the actual TypeScript 7 API and compare where native narrowing is already enough versus where reusable composition still has gaps.
120
nyaomaru @nyaomaru-dev.bsky.social · 02/09/2026
Thank you so much! 😺 This is a really valuable point. I had mostly been looking at existing narrowing patterns through a TypeScript 6 lens, but TypeScript 7 may change that landscape quite a bit, especially around AST types, kind narrowing, and the role of the existing isX helpers.
120
nyaomaru @nyaomaru-dev.bsky.social · 01/09/2026
Treat boundary data as unknown. Validate it with composable guards, then let `safeParse` narrow the result. A type assertion performs no runtime check. is-kit.dev/guides/valid... #typescript #opensource #cleancode
is-kit.dev
Validate unknown in TypeScript Without a Schema Library | is-kit
Validate unknown TypeScript values with small composable type guards and safeParse, without adopting a schema-first validation workflow.
030