spire-plugin-prettier

5.0.8 • Public • Published

spire-plugin-prettier

Prettier plugin for Spire.

Hooks

  • setup Adds format command and prepares prettier arguments.
  • precommit Adds prettier linter.
  • run Runs prettier.

Options

  • Plugin ['spire-plugin-prettier', options']

    • command <string> Command to run prettier on. Defaults to format.
    • prettierConfig <string> Path to default [prettier] configuration. Defaults to ./config.js.
    • allowCustomConfig <boolean> Whether to allow user-provided config. If this option is false and there's custom prettier config found it will throw an error. Defaults to true.
    • autosetPrettierConfig <boolean> Whether to automatically set Prettier config in package.json on install or not. Defaults to true. Note: this is essential step for eslint-plugin-prettier and IDE integrations. You can also use prettier.config.js to re-export & modify target config, although not recommended. Prefer prettier prop when possible.
    • prettierIgnore <string> Path to default .prettierignore. Defaults to .gitignore
    • allowCustomIgnore <boolean> Whether to allow user-provided .prettierignore. If this option is false and there's custom ignore file found it will throw an error. Defaults to true.
    • glob <string> Default glob of files to write. Defaults to **/*.+(js|json|less|css|ts|tsx|md).
  • CLI npx spire format [args]

    • Passes all arguments as-is to jest.

Readme

Keywords

none

Package Sidebar

Install

npm i spire-plugin-prettier

Weekly Downloads

43

Version

5.0.8

License

MIT

Unpacked Size

15.6 kB

Total Files

8

Last publish

Collaborators

  • sbekrin
  • researchgate-bot
  • stefanhoth
  • mdio