What is Nostr?
Callionica /
npub1emh…q9c5
2024-06-20 08:22:41
in reply to nevent1q…uyvq

Callionica on Nostr: Is it possible that you’re confusing cast syntax with generic argument passing ...

Is it possible that you’re confusing cast syntax with generic argument passing syntax?

`<type>fn()` is a cast to `type`.
`fn<type>()` passes `type` as a generic argument.

You’re getting `number` because you’re casting to `number` (Typescript calls this a “type assertion”)
Author Public Key
npub1emhf6ln8qk2xxgdegr45a3xmwwxpsd3d9tpxmzwfa2hey6w8lc9sqlq9c5