Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

clutz: output type guards for goog.base functions #710

Open
ribrdb opened this issue Mar 18, 2018 · 1 comment
Open

clutz: output type guards for goog.base functions #710

ribrdb opened this issue Mar 18, 2018 · 1 comment

Comments

@ribrdb
Copy link

ribrdb commented Mar 18, 2018

It would be handy if clutz generated type guards for the goog.isX functions:

    function isArray(val: any): val is Array<any>;
    function isBoolean(val: any): val is boolean;
    function isDateLike(val: any): val is goog.date.DateLike;
    function isDef<T>(val: T | undefined): val is T;
    function isDefAndNotNull<T>(val: T | undefined | null): val is T;
    function isFunction(val: any): val is Function;
    function isNull(val: any): val is null;
    function isNumber(val: any): val is Number;
    function isObject(val: any): val is Object;
    function isString(val: any): val is string;
@rkirov
Copy link
Contributor

rkirov commented Apr 25, 2018

We ran into this during migration of .js to .ts, it would be helpful.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants