Skip to content

damiancipolat/Dynamicy-Type-Check-in-js

Repository files navigation

Dynamic Type check in our javascript projects.

Well, I build this repository, because I consider it necessary to give my opinion based on my experience on how it is the best way to check data types in our projects using javascript. I think that JS is a great language that today is changing many ways of how to program, all this makes many programmers the lack of a static type checking system in variables at the time of compilation, causes in many people fear and uncertainty on how to handle certain aspects of an application.

There are basically two approaches, using "npm" modules or using the JS "typeof" native function.

Using some famous npm module and my own module:

Using only pure JS:

Go to the next link to see 3 differents techniques to handle type check using only js.

My custom parser type module:

Go to this link to see my last experiments, a function that decorate another function adding a type validation layer before run the function. The code use a special method of name the variables in a function.

About

I set up this repository to demostrate several different ways to do dynamic data check types in our javascript code, I will perform them using nodejs.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published