Skip to content

Writes a log message to stderr even when everything is OK #249

Closed
@SteveSandersonMS

Description

@SteveSandersonMS

When ts-loader starts up, it logs messages like this to stderr:

ts-loader: Using typescript@1.8.10 and /some/path/tsconfig.json

This is because the log function calls console.log.apply(console, message), and the console variable is overridden as follows:

var console = new Console(process.stderr);

I know most of the log values outputted by ts-loader are errors, but the Using typescript@... message isn't an error. Logging it to stderr isn't great, because many apps are configured to treat stderr output as actual errors (and write it to a DB, email an administrator, etc.)

I am aware this can be suppressed by setting silent to true, but then this suppresses other potentially useful error information.

Would it be possible not to log the Using typescript@... to stderr, but still log other messages to stderror?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions