UNPKG

@stryke/prisma-trpc-generator

Version:

A fork of the prisma-trpc-generator code to work in ESM with Prisma v6.

24 lines (22 loc) 536 B
import prettier from "prettier"; //#region src/utils/format-file.ts async function formatFile(content) { const options = await prettier.resolveConfig(process.cwd()); let formatOptions = options; if (!options) formatOptions = { trailingComma: "all", tabWidth: 2, printWidth: 80, bracketSpacing: true, semi: true, singleQuote: true, useTabs: false }; return await prettier.format(content, { ...formatOptions, parser: "typescript" }); } //#endregion export { formatFile }; //# sourceMappingURL=format-file.mjs.map