ansi-colors icon indicating copy to clipboard operation
ansi-colors copied to clipboard

Update index.d.ts

Open ghost opened this issue 5 years ago • 1 comments

Is there any harm in doing this? So I don't have to do nested templates like:

    this.log(`Inbox contains ${green(`${inbox.files.length}`)} reports:`);
    this.log(`Valid:   ${green(`${inbox.accepted.length}`)}`);
    this.log(`Invalid: ${green(`${inbox.rejected.length}`)}`);

and just do...

    this.log(`Inbox contains ${green(inbox.files.length)} reports:`);
    this.log(`Valid:   ${green(inbox.accepted.length)}`);
    this.log(`Invalid: ${green(inbox.rejected.length)}`);

ghost avatar Sep 10 '20 15:09 ghost

Hi @cncshaggy ... sorry for not responding sooner and thanks for the PR!

Since the input is technically "cast" to a string here, I believe this should be any. (Also, null and undefined are valid inputs, which return an empty string)

If you'd like to update that to any, I'll get this merged.

doowb avatar Jun 08 '21 14:06 doowb