typeof operator is a bit like operating a clapped-out old car (or an early model Dell Inspiron). It gets the job done (mostly) and you learn to work around the quirks – but you probably aspire to something better.
In this article I’ll give a brief overview of
typeof before introducing a tiny new function which is a fully-loaded, more reliable alternative that works directly with the language internals.
View original 1,647 more words