Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@anolilab/prettier-config

anolilab1.7kMIT6.0.1TypeScript support: included

Prettier shareable config for Anolilab.

css, anolilab, lint, prettier, config, prettier-config

readme

Prettier shareable configuration

Package that contains shareable configuration for prettier — a popular opinionated code formatter.

typescript-image npm-image license-image


Daniel Bannert's open source work is supported by the community on GitHub Sponsors


Install

npm install --dev-save prettier @anolilab/prettier-config
yarn add -D prettier @anolilab/prettier-config
pnpm add -D prettier @anolilab/prettier-config

Usage

If you don’t have a .prettierrc.js or the other supported file names and .prettierignore, we can create the file for you after installing @anolilab/prettier-config, call pnpm prettier-config:install.

Note: If the script detects an existing .prettierrc.js file, it will not overwrite it.

<summary>File content of the `.prettierrc.js`</summary>
module.exports = {
    // brackets are required for arrow function parameter, even when there is only one parameter
    arrowParens: "always",
    // spaces are required at the beginning and end of the braces
    bracketSpacing: true,
    // formats quoted code embedded
    embeddedLanguageFormatting: "auto",
    // lf for newline
    endOfLine: "lf",
    // decide whether to break the html according to the display style
    htmlWhitespaceSensitivity: "css",
    // No need to automatically insert @prettier at the beginning of the file
    insertPragma: false,
    // use double quotes instead of single quotes in jsx
    jsxSingleQuote: false,
    // max 160 characters per line
    printWidth: 160,
    // use default break criteria
    proseWrap: "preserve",
    // object's key is quoted only when necessary
    quoteProps: "as-needed",
    rangeEnd: Number.POSITIVE_INFINITY,
    // format the entire contents of the file
    rangeStart: 0,
    // no need to write the beginning @prettier of the file
    requirePragma: false,
    // semicolon at the end of the line
    semi: true,
    // use single quotes
    singleQuote: false,
    // use 4 spaces for indentation
    tabWidth: 4,
    // all comma at the end
    trailingComma: "all",
    // use spaces instead of indentations
    useTabs: false,
    // vue files script and style tags indentation
    vueIndentScriptAndStyle: false,
}

Supported Node.js Versions

Libraries in this ecosystem make the best effort to track Node.js’ release schedule. Here’s a post on why we think this is important.

Contributing

If you would like to help take a look at the list of issues and check our Contributing guild.

Note: please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms.

Credits

License

The anolilab javascript-style-guide is open-sourced software licensed under the MIT license

changelog

@anolilab/prettier-config 6.0.1 (2025-05-31)

Bug Fixes

  • deps: update dependency prettier to v3.0.3 (#891) (21d2229)
  • deps: update minor updates (minor) (#896) (d5132c8)

Miscellaneous Chores

  • add new linting scripts and update dependencies (655a866)

@anolilab/prettier-config 6.0.0 (2025-05-26)

⚠ BREAKING CHANGES

  • prettier-config: changed post-install script to a bin command call, removed support for prettier v2 Signed-off-by: prisis d.bannert@anolilab.de

Features

  • prettier-config: removed post-install script, updated dev-dependencies, allowed node 23 (d1866a0)

Bug Fixes

  • prettier-config: removed @anolilab/package-json-utils (804c365)

Miscellaneous Chores

  • clean update after code changes (c1ec624)
  • prettier-config: updated dev dependencies (18b59d1)
  • remove deprecated ESLint and Prettier configurations, update project structure and dependencies (7b269ed)
  • update node engine compatibility across multiple packages (8755783)
  • update prettier-config dependencies to latest versions (ae0c554)
  • updated dev dependencies (89cb5c7)

Continuous Integration

@anolilab/prettier-config 5.0.14 (2023-12-22)

Miscellaneous Chores

Dependencies

  • @anolilab/semantic-release-preset: upgraded to 8.0.3

@anolilab/prettier-config 5.0.13 (2023-11-02)

Bug Fixes

Dependencies

  • @anolilab/package-json-utils: upgraded to 3.0.9
  • @anolilab/semantic-release-preset: upgraded to 8.0.2

@anolilab/prettier-config 5.0.12 (2023-10-31)

Bug Fixes

Dependencies

  • @anolilab/package-json-utils: upgraded to 3.0.8
  • @anolilab/semantic-release-preset: upgraded to 8.0.1

@anolilab/prettier-config 5.0.11 (2023-09-29)

Miscellaneous Chores

Dependencies

  • @anolilab/semantic-release-preset: upgraded to 8.0.0

@anolilab/prettier-config 5.0.10 (2023-09-29)

Bug Fixes

  • Update dependencies to latest versions (6cdc09b)

Dependencies

  • @anolilab/package-json-utils: upgraded to 3.0.7
  • @anolilab/semantic-release-preset: upgraded to 7.0.5

@anolilab/prettier-config 5.0.9 (2023-09-27)

Miscellaneous Chores

Dependencies

  • @anolilab/semantic-release-preset: upgraded to 7.0.4

@anolilab/prettier-config 5.0.8 (2023-09-26)

Bug Fixes

  • Various project dependencies have been updated to their respective newer versions. This covers multiple packages such as '@babel/cli', '@babel/core', '@nrwl/js', and 'eslint' among others within the package.json file. This upgrade is necessary to ensure the utilization of the most recent features, optimization and security improvements of the updated packages, and it also helps to maintain overall project consistency. (38535ab)

Styles

Dependencies

  • @anolilab/package-json-utils: upgraded to 3.0.6
  • @anolilab/semantic-release-preset: upgraded to 7.0.3

@anolilab/prettier-config 5.0.7 (2023-09-22)

Styles

Dependencies

  • @anolilab/semantic-release-preset: upgraded to 7.0.2

@anolilab/prettier-config 5.0.6 (2023-09-21)

Miscellaneous Chores

  • update package versions and Node.js versions in actions (ba1bd5f)
  • updated deps (a287003)

Continuous Integration

  • downgrade semantic-release to v21 and conventional-changelog-conventionalcommits to v6.1 (30d8cd7)

Dependencies

  • @anolilab/semantic-release-preset: upgraded to 7.0.0

@anolilab/prettier-config 5.0.5 (2023-09-14)

Styles

  • cs fixes based on new rules (b99c020)

Miscellaneous Chores

  • deps: update dependency vitest to ^0.34.4 (#755) (3246b55)

Dependencies

  • @anolilab/semantic-release-preset: upgraded to 6.0.6

@anolilab/prettier-config 5.0.4 (2023-08-30)

Miscellaneous Chores

  • deps: update dependency prettier to ^3.0.3 (#737) (6966403)
  • deps: update dependency semantic-release to ^21.1.1 (#738) (ee6e926)
  • deps: update dependency vitest to ^0.34.3 (#739) (67dd404)

Dependencies

  • @anolilab/package-json-utils: upgraded to 3.0.5
  • @anolilab/semantic-release-preset: upgraded to 6.0.5

@anolilab/prettier-config 5.0.3 (2023-08-10)

Dependencies

  • @anolilab/package-json-utils: upgraded to 3.0.4
  • @anolilab/semantic-release-preset: upgraded to 6.0.4

@anolilab/prettier-config 5.0.2 (2023-08-04)

Bug Fixes

  • Update package dependencies (a8786f2)

Dependencies

  • @anolilab/package-json-utils: upgraded to 3.0.3
  • @anolilab/semantic-release-preset: upgraded to 6.0.3

@anolilab/prettier-config 5.0.1 (2023-07-26)

Bug Fixes

  • included 'skip.js' in package.json for several packages (1c84b33)

Miscellaneous Chores

  • deps: update dependency prettier to v3 (f9c2fb6)

Dependencies

  • @anolilab/package-json-utils: upgraded to 3.0.2
  • @anolilab/semantic-release-preset: upgraded to 6.0.2

@anolilab/prettier-config 5.0.0 (2023-07-18)

⚠ BREAKING CHANGES

Bug Fixes

Miscellaneous Chores

  • "Update package versions in pnpm-lock.yaml" (9c24c65)

Dependencies

  • @anolilab/package-json-utils: upgraded to 3.0.1
  • @anolilab/semantic-release-preset: upgraded to 6.0.1

@anolilab/prettier-config 4.2.1 (2023-07-05)

Bug Fixes

  • Refactor async functions to use async/await and update tsconfig.json (2a59d6e)

Miscellaneous Chores

  • Reorganize Prettier config and update README examples (cc2a4be)

Dependencies

  • @anolilab/package-json-utils: upgraded to 2.0.1
  • @anolilab/semantic-release-preset: upgraded to 5.0.1

@anolilab/prettier-config 4.2.0 (2023-07-03)

Features

  • Update dependencies version in pnpm-lock.yaml (1f75f7b)

Styles

  • "Rearrange order of task definitions and disable ESLint on non-literal fs filename" (d48a8c0)

Miscellaneous Chores

  • removed "semantic-release-npm-deprecate" not working like expected (a988c89)
  • Update deprecation versions in releaserc.json files (b7b7ab7)

Dependencies

  • @anolilab/package-json-utils: upgraded to 2.0.0
  • @anolilab/semantic-release-preset: upgraded to 5.0.0

@anolilab/prettier-config 4.1.3 (2023-06-29)

Bug Fixes

  • update postinstall.ts to dynamically import prettier-config (816c421)

Miscellaneous Chores

@anolilab/prettier-config 4.1.2 (2023-06-28)

Bug Fixes

  • updated lock, updated @anolilab/package-json-utils and removed baseUrl in the tsconfig that was in the wrong place (cb08fb5)

Dependencies

  • @anolilab/semantic-release-preset: upgraded to 4.0.3

@anolilab/prettier-config 4.1.1 (2023-06-28)

Bug Fixes

  • Update package dependencies versions (7aec41d)

Miscellaneous Chores

  • prettier-config: update readme (b6da6a0)
  • update readme (518bb22)
  • update readme to remove eslint (3c714b2)

Dependencies

  • @anolilab/package-json-utils: upgraded to 1.5.1
  • @anolilab/semantic-release-preset: upgraded to 4.0.2

@anolilab/prettier-config 4.1.0 (2023-06-25)

Features

  • extended prettier-config, with overrides for .eslintrc, .prettierrc, .stylelintrc, package.json, *.yml,.yaml (1e24536)

@anolilab/prettier-config 4.0.11 (2023-06-24)

Bug Fixes

  • fixed export of rangeEnd in postinstall (dc40767)

Miscellaneous Chores

  • grouped more packages together for renovate (67eb228)

@anolilab/prettier-config 4.0.10 (2023-06-23)

Dependencies

  • @anolilab/semantic-release-preset: upgraded to 4.0.1

@anolilab/prettier-config 4.0.9 (2023-06-23)

Dependencies

  • @anolilab/package-json-utils: upgraded to 1.5.0
  • @anolilab/semantic-release-preset: upgraded to 4.0.0

@anolilab/prettier-config 4.0.8 (2023-06-22)

Dependencies

  • @anolilab/package-json-utils: upgraded to 1.4.1
  • @anolilab/semantic-release-preset: upgraded to 3.1.3

@anolilab/prettier-config 4.0.7 (2023-06-22)

Dependencies

  • @anolilab/package-json-utils: upgraded to 1.4.0
  • @anolilab/semantic-release-preset: upgraded to 3.1.2

@anolilab/prettier-config 4.0.6 (2023-06-15)

Dependencies

  • @anolilab/package-json-utils: upgraded to 1.3.0
  • @anolilab/semantic-release-preset: upgraded to 3.1.1

@anolilab/prettier-config 4.0.5 (2023-06-11)

Bug Fixes

  • removed the prefix (m|c) for the postinstall file creation based on package.json type (6c786b4)

@anolilab/prettier-config 4.0.4 (2023-06-11)

Dependencies

  • @anolilab/semantic-release-preset: upgraded to 3.1.0

@anolilab/prettier-config 4.0.3 (2023-06-11)

Bug Fixes

  • use the projectPath from @anolilab/package-json-utils (1574f21)

@anolilab/prettier-config 4.0.2 (2023-06-11)

Dependencies

  • @anolilab/package-json-utils: upgraded to 1.2.0

@anolilab/prettier-config 4.0.1 (2023-06-10)

Dependencies

  • @anolilab/package-json-utils: upgraded to 1.1.0

@anolilab/prettier-config 4.0.0 (2023-06-10)

⚠ BREAKING CHANGES

  • Changed the package to support cjs and mjs, so the type module was removed

Signed-off-by: prisis d.bannert@anolilab.de

Features

  • switched prettier-config to typescript (c014026)

@anolilab/prettier-config 3.1.2 (2023-06-10)

Dependencies

  • @anolilab/semantic-release-preset: upgraded to 3.0.0

@anolilab/prettier-config 3.1.1 (2023-05-25)

Dependencies

  • @anolilab/semantic-release-preset: upgraded to 2.2.1

@anolilab/prettier-config 3.1.0 (2022-10-24)

Features

  • updated deps and start using node postfix for node libs (02a71cb)

@anolilab/prettier-config 3.0.2 (2022-07-16)

Bug Fixes

@anolilab/prettier-config 3.0.1 (2022-05-11)

Bug Fixes

  • update all deps of the package and fixes found code style issues (2776ecd)

@anolilab/prettier-config 3.0.0 (2022-02-15)

⚠ BREAKING CHANGES

  • remove old node version from our supported versions

Signed-off-by: prisis d.bannert@anolilab.de

Bug Fixes

Performance Improvements

  • support for v12, v14 was removed from our supported versions of node (83d6a80)

@anolilab/prettier-config 2.0.6 (2022-01-12)

Bug Fixes

  • added ts-check to the prettier config (6d03d06)

@anolilab/prettier-config 2.0.5 (2021-12-30)

Bug Fixes

@anolilab/prettier-config 2.0.4 (2021-09-02)

Bug Fixes

  • added funding to the package (f90d18f)

@anolilab/prettier-config 2.0.3 (2021-09-02)

Bug Fixes

  • fixed release flow in all packages (8c5ec13)

@anolilab/prettier-config 2.0.2 (2021-08-17)

Bug Fixes

  • fixed wrong file creation of prettierrc.cjs (4ab35b3)

@anolilab/prettier-config 2.0.1 (2021-04-20)

Bug Fixes

  • added missing exit code to process.exit (a94e9ed)

@anolilab/prettier-config 2.0.0 (2021-04-19)

⚠ BREAKING CHANGES

  • upgraded node version to v12 and es modules

Features