function pageGoneMessage
pageGoneMessage(argv?: readonly string[]): string

What to SAY when the page has gone — the farewell, not the going.

There is nothing to recover and nothing to offer: a REPL's whole value is the page it is holding — the bindings, the DOM, the module state — and all of it went at once. Reopening one would not bring any of it back; it would be the session you get by running the command again, which the shell already remembers. So the message says what was lost and what to type, and the caller ends the process rather than sitting at a prompt that cannot answer anything.

import { pageGoneMessage } from './index.ts';

pageGoneMessage(['node', 'cli.ts', 'repl', 'a.ts']).includes('qunitx repl a.ts'); // true

Parameters

optional
argv: readonly string[] = [process.argv]

Return Type

string

Usage

import { pageGoneMessage } from "lib/commands/repl/index.ts";