poksme
banner
poks.me
poksme
@poks.me
Click Clack on my keyboard
Beep Boop on my gameboy
Plip Plop on my coffee
November 30, 2025 at 4:58 PM
Je veux bien te MP si tu me follow back 🙂 (plus trop sur insta btw)
November 6, 2025 at 12:45 PM
August 20, 2025 at 5:42 PM
Didn’t want to believe this was true. It’s true.
August 8, 2025 at 6:13 AM
testing again with chatgpt 5
August 8, 2025 at 6:11 AM
(real, one-shot :p )
August 8, 2025 at 6:08 AM
Thanks @stevebarman.com @alexis.brissard.fr @kastor.fr for looking into it.
December 6, 2024 at 11:25 AM
Found out this morning that this is not considered a bug by Typescript team :

github.com/microsoft/Ty...

```typescript
const x = true ? 'I am a string' : {} // type of `x` is: {}
```

This is a valid subtype reduction since strings are "object-like".
Empty object in ternary operator produces invalid type · Issue #50171 · microsoft/TypeScript
Bug Report 🔎 Search Terms empty object, {}, inferred type 🕗 Version & Regression Information This is the behavior in every version I tried, and I reviewed the FAQ ⏯ Playground Link Playground link ...
github.com
December 6, 2024 at 11:23 AM
This is pseudo code to recreate the typing issue. I have no problem with undefined returning function, I don’t want to change any behavior, only for TS to infer types properly.

But thank you :)
December 5, 2024 at 6:19 PM