Skip to content
/ fmt Public

Dprint wrapper to programmatically format source files in memory

License

Notifications You must be signed in to change notification settings

zwave-js/fmt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

@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;

About

Dprint wrapper to programmatically format source files in memory

Resources

License

Stars

Watchers

Forks

Packages

No packages published