Add is.boundFunction()

This commit is contained in:
Darren Scerri 2017-11-08 13:39:01 +01:00
parent 89fc424975
commit 4cb5fc391a
3 changed files with 25 additions and 1 deletions

View file

@ -95,6 +95,7 @@ namespace is { // tslint:disable-line:no-namespace
export const generatorFunction = isFunctionOfType('GeneratorFunction');
export const asyncFunction = isFunctionOfType('AsyncFunction');
export const boundFunction = (value: any) => function_(value) && !value.hasOwnProperty('prototype');
export const regExp = isObjectOfType('RegExp');
export const date = isObjectOfType('Date');