News for hackers. Stuff that matters.
Re:TypeScript 3.5 by MaulingMonkey on Thursday May 30, 2019 @04:46AM (#20049440)
RE: JSON: I've started tagging my JSON blobs as `unknown` and then using type guards (typeof, instanceof, field access existence checks, Array.isArray checks, user defined type guards[1], etc.) my way to inferring the shape of that JSON blob is as expected, and it seems to work pretty well.

[1] https://www.typescriptlang.org/docs/handbook/advanced-types....

There are no comments on this comment yet.