0.3.0 • Published 3 months ago

@detra-lab/prettier-config v0.3.0

Weekly downloads
-
License
Apache License 2....
Repository
github
Last release
3 months ago

Prettier Config

NPM Version NPM Downloads

Prettier is a highly effective tool that specializes in handling code formatting styles. :sparkles: We have bundled our configuration to make it easily shareable across multiple projects.

Getting started

Install Prettier and the related configuration as a devDependencies:

pnpm add -D @detra-lab/prettier-config prettier

Reference it in your package.json:

{
  "name": "my-cool-library",
  "version": "1.0.0",
  "prettier": "@detra-lab/prettier-config"
}

If you don’t want to use package.json, you can choose any of the supported extensions to export a string, e.g. .prettierrc.json:

"@detra-lab/prettier-config"

Note: This method doesn't offer a way to extend the configuration and override some properties. If you need to do that, import the file in a .prettierrc.js file and export the modifications:

module.exports = {
  ...require('@detra-lab/prettier-config'),
  semi: true
};

Use the --write flag to format a file in place.

pnpx prettier . --write --ignore-unknown

Config

Check the .prettierrc.json file if you want to inspect the configuration.

Code of Conduct

Help us keep the project open and inclusive. Please read and follow our Code of Conduct.

License

Apache License 2.0

0.3.0

3 months ago

0.2.1

6 months ago

0.2.0

10 months ago

0.1.0

1 year ago