type alias ReplFailure

Every way a REPL can fail to open: the same config failures a run has, plus the two of its own — a browser that cannot be driven over CDP, and a preload file that will not compile.

import { Failure } from '../task/index.ts';

// Defined, not invoked: a real failure comes back from `repl(...).result()`.
function explain(failure: ReplFailure) {
  return `${failure.code}: ${Failure.format(failure)}`; // 'UnsupportedBrowser: …'
}

Definition

Usage

import { type ReplFailure } from "lib/api/repl.ts";