UNPKG

@lingui/cli

Version:

Lingui CLI to extract messages, compile catalogs, and manage translation workflows

13 lines (12 loc) 508 B
import { resolveCatalogPath, getEntryName } from "./resolveCatalogPath.js"; import { DEFAULT_TEMPLATE_NAME, ENTRY_NAME_PH } from "./constants.js"; export function resolveTemplatePath(entryPoint, output, rootDir, catalogExtension) { let templateName; if (output.includes(ENTRY_NAME_PH)) { templateName = DEFAULT_TEMPLATE_NAME; } else { templateName = getEntryName(entryPoint); } return resolveCatalogPath(output, entryPoint, rootDir, templateName, catalogExtension); }