UNPKG

accelerator-tool

Version:

The Accelerator devtool. Generally invoked with accelerator-tool, npx accelerator-tool, or xlr8r.

14 lines (11 loc) 369 B
import { getNounNormalizationTable, } from './getNounNormalizationTable'; export function normalizeNoun(noun) { const normalized = String(getNounNormalizationTable()[noun]); if (!normalized) { throw new Error(`The subcommand ${noun} was not recognized by ` + 'the accelerator-tool new command.'); } return normalized; }