In software engineering, we try to discover and eliminate bugs as soon as possible. One of most important heuristics here is validation of input/output on functions and methods. If you are going with TypeScript or Flow, you are fine. But if not? Then we have to manually validate at least the input (arguments). But what would be the best way of doing this?

The first thing that comes to mind is the aproba library. It’s “ridiculously” light-weight and equally popular:

In software engineering, we try to discover and eliminate bugs as soon as possible. One of most important heuristics here is validation of input/output on functions and methods. If you are going with TypeScript or Flow, you are fine. But if not? Then we have to manually validate at least the input (arguments). But what would be the best way of doing this?
The first thing that comes to mind is the aproba library. It’s “ridiculously” light-weight and equally popular: […]