Skip to content

Create a Prettier config based on the formatting of existing JavaScript code

Notifications You must be signed in to change notification settings

nickmccurdy/create-prettierrc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

create-prettierrc

Create a Prettier config based on the formatting of existing JavaScript code

Usage

import createPrettierrc from "create-prettierrc";

createPrettierrc('console.log("Hello, world!")');
{
  "endOfLine": "lf",
  "jsxSingleQuote": false,
  "requirePragma": false,
  "semi": true,
  "singleQuote": false
}

Limitations

Currently supports a limited number of Prettier config options using only JavaScript and JSX (React) syntax

About

Create a Prettier config based on the formatting of existing JavaScript code

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project