nyaomaru | Game Developer

2K posts

nyaomaru | Game Developer banner
nyaomaru | Game Developer

nyaomaru | Game Developer

@nyaomaru_dev

Funny frontend engineer (React / Vue / TypeScript) I made a tiny game about running away from work 👇Let's Play https://t.co/akmRpgWwzi

The Netherlands, Heerlen انضم Nisan 2020
466 يتبع11.8K المتابعون
nyaomaru | Game Developer
nyaomaru | Game Developer@nyaomaru_dev·
TypeScript: JSON.parse gives you unknown. Don’t trust it. → prove it first
nyaomaru | Game Developer tweet media
English
0
0
0
173
nyaomaru | Game Developer
nyaomaru | Game Developer@nyaomaru_dev·
unknown type is unknown. So, if you want to use correctly, you should do type narrowing. import { isString, isNull, or } from 'is-kit'; const input: unknown; const isNullableString = or(isString, isNull); if (isNullableString(input)) { input; // string | null 😸 }
English
0
0
0
201
Sahil
Sahil@sahill_og·
The life of Gen Z : - College degree is worthless - Rent is half your paycheck - Al is replacing your job - Houses cost 30x your salary - Boomers asking why you're stressed
English
8
2
41
1.5K
nyaomaru | Game Developer
nyaomaru | Game Developer@nyaomaru_dev·
Handling `unknown` in TypeScript is painful. Most tools separate validation from your code. I wanted something that just extends your existing `if` statements. dev.to/nyaomaru/handl…
English
0
0
1
204
nyaomaru | Game Developer
nyaomaru | Game Developer@nyaomaru_dev·
This is not a library comparison. It’s a design question: 👉 Where do you enforce type safety? - Zod → at the boundary - is-kit → inside control flow Same problem, different layer. Read more 👇 dev.to/nyaomaru/is-ki…
GIF
English
0
0
1
215
nyaomaru | Game Developer
nyaomaru | Game Developer@nyaomaru_dev·
Honored to be featured in TypeScript Trends 🙏 I’ve been exploring a slightly different approach to validation: - Zod → schema-first - is-kit → composable type guards Not better/worse, just different trade-offs. github.com/nyaomaru/is-kit
Dor Moshe@DorMoshe

📰👨‍💻 I just published #Angular #TypeScript Trends #416 dormoshe.io/newsletters/41… @nyaomaru_dev @thepracticaldev @UssfSlk @brendonovich @dormoshe #dormosheio #javascript #frontend #webdev

English
0
0
0
365
nyaomaru | Game Developer
nyaomaru | Game Developer@nyaomaru_dev·
Zod feels great at boundaries. But inside your app? - if (isUser(x)) - arr.filter(isUser) Type guards fit the control flow better. 👉 schema vs guard is a design choice, not a tool choice Full comparison 👇 dev.to/nyaomaru/is-ki…
GIF
English
0
0
1
142
nyaomaru | Game Developer
nyaomaru | Game Developer@nyaomaru_dev·
Zod vs is-kit — same goal, different philosophy. - Zod → schema → type - is-kit → guard → control flow narrowing Not “which is better?” 👉 Where do you enforce type safety in your design? Built a comparison 👇 dev.to/nyaomaru/is-ki…
English
0
0
1
193
nyaomaru | Game Developer
nyaomaru | Game Developer@nyaomaru_dev·
{} is NOT an empty object. It means: "any value except null and undefined" Yes, even strings and numbers.
nyaomaru | Game Developer tweet media
English
0
0
2
202
nyaomaru | Game Developer
nyaomaru | Game Developer@nyaomaru_dev·
TypeScript type system: primitives → objects → unions → unknown A carefully built structure. Add "any" at the top, and type safety disappears instantly.
GIF
English
0
0
0
206