Giter Club home page Giter Club logo

prettier-config's Introduction

@elgato/prettier-config

Prettier configuration used by Elgato projects.

@elgato/prettier-config npm package Join the Marketplace Makers Discord Elgato homepage

Usage

  1. Install @elgato/prettier-config.
npm install @elgato/prettier-config --save-dev
  1. Edit your package.json to reference the configuration.
"prettier": "@elgato/prettier-config"

Configuration

Prettier

Option Value
endOfLine lf
printWidth 120
singleQuote ❌ Prefer double
semi ✅ Prefer semicolons
tabWidth 4 for .json and .md, 2 for .yml
useTabs ✅ Except .json, .md and .yml
trailingComma All

Multiline arrays

Option Value
multilineArraysWrapThreshold -1 (manual)

Sort imports

Option Value
importOrder Third-party modules first.
importOrderSeparation
importOrderSortSpecifiers
importOrderCaseInsensitive
importOrderParserPlugins TypeScript

Overrides

Overriding configuration can be achieved by removing the prettier entry from package.json, in favour of a .prettierrc.js file. For example, to prefer spaces over tabs:

module.exports = {
    ...require("@elgato/prettier-config"),
    tabWidth: 2,
    useTabs: false,
};

Recognitions

This project wishes to express thanks to those who work on Prettier, and Prettier plugins, with particular thanks to:

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.