docs: Add TSDoc for TemplateStringsArray overload

This commit is contained in:
ExE Boss 2019-04-28 21:50:00 +02:00
parent 1b168d47db
commit f4f266da7f
No known key found for this signature in database
GPG key ID: BF4FA5DD733D8D1A
2 changed files with 21 additions and 4 deletions

View file

@ -1,4 +1,4 @@
import {expectType} from 'tsd';
import {expectType, expectError} from 'tsd';
import chalk = require('.');
// - Helpers -
@ -15,6 +15,9 @@ expectType<boolean>(chalk.supportsColor.hasBasic);
expectType<boolean>(chalk.supportsColor.has256);
expectType<boolean>(chalk.supportsColor.has16m);
// -- `supportsColor` is not a member of the Chalk interface --
expectError(chalk.reset.supportsColor);
// - Chalk -
// -- Instance --
expectType<chalk.Chalk>(new chalk.Instance({level: 1}));