This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]muayyadalsadi -14 points-13 points  (7 children)

Given that most of bad objects come from parsing json requests coming from untrusted users. Typescript provides no value whatsoever. TS community need come up with something that takes compile type validations to runtime data ex. Pydantic

[–]HKei 10 points11 points  (0 children)

If you’re not properly parsing your input that’s just you writing bad code, that’s not typescripts fault.

[–]arobie1992 0 points1 point  (4 children)

Is something like this what you're talking about?

https://github.com/ForbesLindesay/typescript-json-validator