Skip to content

numToStr/prettierrc.nvim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

prettierrc.nvim

Editor settings via prettier config

Installation

use('numToStr/prettierrc.nvim')
Plug 'numToStr/prettierrc.nvim'

And that's it. Restart your neovim to see the magic.

Support

Options

Following options are supported:

Files

Following config files are supported in the respective order.

  • .prettierrc
  • .prettierrc.json
  • .prettierrc.yml
  • .prettierrc.yaml
  • .prettierrc.toml

Keep in mind, there is no support for nested configuration as of now.

  • Supported
{
  "trailingComma": "es5",
  "tabWidth": 4,
  "printWidth": 100
}
  • Not Supported
{
  "semi": false,
  "overrides": [
    {
      "files": "*.test.js",
      "options": {
        "semi": true
      }
    },
    {
      "files": ["*.html", "legacy/**/*.js"],
      "options": {
        "tabWidth": 4
      }
    }
  ]
}

Limitation

Following filetype/format are not supported

  • .prettierrc.{js,cjs} and .prettierrc.config.{js,cjs} - I am not going to create a javascipt parser
  • package.json (prettier option) - Technically, it's possible to support but I am lazy.

Contributing

You can contribute to the project by filing bug reports or submit PR :)

Credits

Releases

No releases published

Sponsor this project

 

Packages

No packages published

Languages