1.0.0 • Published 9 months ago
@zwave-js/fmt v1.0.0
@zwave-js/fmt
Dprint wrapper to programmatically format source files in memory.
This project is meant for internal use in the node-zwave-js
project.
Install
yarn add --dev @dprint/formatter @dprint/json @dprint/markdown @dprint/typescript @zwave-js/fmt
Usage
import { formatWithDprint } from "@zwave-js/fmt";
const formatted = formatWithDprint(
"/path/to/repo/root",
"/path/to/repo/root/path/to/file.ts",
"const foo = 1 "
)
console.log(formatted);
// prints:
// const foo = 1;
1.0.0
9 months ago