Skip to content

Prettier Configuration File #7

@pcsmomo

Description

@pcsmomo

Summary

This issue is about adding a Prettier configuration file to the repository to keep our code formatting

Problem

At the moment, our project doesn't have a standard code formatting setup. This means different developers might use different formatting rules, which can lead to code styles being all over the shop. This makes it a little pain to review code and can cause unnecessary merge conflicts.

Proposed Solution

Let's chuck a .prettierrc or .prettierrc.json file in the root of the repository with these configuration examples:

ADS ui project

{
    "printWidth": 120,
    "semi": true,
    "singleQuote": true,
    "tabWidth": 4,
    "trailingComma": "es5",
    "plugins": [
        "prettier-plugin-css-order",
        "prettier-plugin-organize-attributes",
        "prettier-plugin-tailwindcss"
    ]
}

XAS ui project

{
  "printWidth": 80,
  "tabWidth": 2,
  "useTabs": false,
  "semi": true,
  "singleQuote": false,
  "quoteProps": "as-needed",
  "jsxSingleQuote": false,
  "trailingComma": "es5",
  "bracketSpacing": true,
  "bracketSameLine": false,
  "arrowParens": "always",
  "plugins": [
    "prettier-plugin-css-order",
    "prettier-plugin-organize-attributes",
    "prettier-plugin-tailwindcss"
  ]
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions