function failureText
failureText(result: Repl.ReplResult): string

A failed result, in the words its kind earns.

Uncaught is what a browser console says about an exception, and belongs only to one the page actually threw. "That file will not bundle" is this REPL answering, and prefixing it would claim the page had refused something it was never shown.

import { failureText } from './command.ts';

failureText({ output: 'boom', failed: true, thrown: true, incomplete: false, tests: [] });
// 'Uncaught boom'
failureText({ output: 'will not bundle', failed: true, incomplete: false, tests: [] });
// 'will not bundle' — nothing threw, so nothing is called uncaught

Parameters

Return Type

string

Usage

import { failureText } from "lib/commands/repl/command.ts";