function error
error(
config: Config,
message: string,
options?: NoticeOptions
): void

A diagnostic that also belongs on stderr — a stack trace, a timeout, a page that crashed.

import * as Reporter from './index.ts';

import type { Config } from '../types.ts';

// Defined, not invoked: writes the trace to the run's error stream, unprefixed.
function reportCrash(config: Config, stack: string) {
  Reporter.error(config, stack, { raw: true, stream: 'error' });
}

Parameters

config: Config
message: string
optional
options: NoticeOptions

Return Type

void

Usage

import { error } from "lib/reporters/index.ts";