Fix #225: provide an equivalent of JS' `typeof x`.

It is introduced as `js.typeOf(x)`.

Supersedes #226. Now `typeOf` in in the package object, as requested.