UNPKG

@gent-js/gent

Version:

template-based data generator.

12 lines (11 loc) 373 B
import { parseCommand } from "../command/index.js"; export function parseAndEmbedCommandExpression(templateFragments) { return templateFragments.map((templateFragment) => { if (typeof templateFragment === "string") { return templateFragment; } else { return parseCommand(templateFragment.expression); } }); }