npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@xwtec/prettier-config

v3.1.0

Published

Prettier Configuration for xwtec projects

Downloads

497

Readme

@xwtec/prettier-config

Prettier Configuration for xwtec projects

Install

# with yarn
yarn add --dev prettier @xwtec/prettier-config

# with npm
npm install --save-dev prettier @xwtec/prettier-config

Configuration

Add following code

module.exports = require('@xwtec/prettier-config');

to prettier.config.js in your project.

Customize

module.exports = require('@xwtec/prettier-config').customize({
  semi: false,
  overrides: [
    {
      files: ['*.js'],
      options: {
        parser: 'meriyah',
      },
    },
  ],
});

Usage

npx prettier "**/*.{js,mjs,cjs,scss,html,vue,css,less,md}"

Options

Global

| Option | value | Description | | :------------------------ | :----- | :------------------------------------------------------- | | bracketSpacing | false | Print spaces between brackets. | | htmlWhitespaceSensitivity | ignore | How to handle whitespaces in HTML. | | semi | true | Print semicolons. | | singleQuote | true | Use single quotes instead of double quotes. | | trailingComma | all | Print trailing commas wherever possible when multi-line. |

*.css

| Option | value | Description | | :---------- | :---- | :------------------------------------------ | | parser | css | Which parser to use. | | singleQuote | false | Use single quotes instead of double quotes. |

*.{gql,graphql}

| Option | value | Description | | :----- | :------ | :------------------- | | parser | graphql | Which parser to use. |

*.{html,htm}

| Option | value | Description | | :----- | :---- | :------------------- | | parser | html | Which parser to use. |

*.{js,jsx,mjs,cjs}

| Option | value | Description | | :----- | :---- | :------------------- | | parser | babel | Which parser to use. |

*.json

| Option | value | Description | | :---------- | :------------- | :------------------------------------------ | | parser | json-stringify | Which parser to use. | | singleQuote | false | Use single quotes instead of double quotes. |

*.json5

| Option | value | Description | | :---------- | :---- | :------------------------------------------ | | parser | json5 | Which parser to use. | | singleQuote | false | Use single quotes instead of double quotes. |

*.less

| Option | value | Description | | :---------- | :---- | :------------------------------------------ | | parser | less | Which parser to use. | | singleQuote | false | Use single quotes instead of double quotes. |

*.{md,markdown}

| Option | value | Description | | :----- | :------- | :------------------- | | parser | markdown | Which parser to use. |

*.mdx

| Option | value | Description | | :----- | :---- | :------------------- | | parser | mdx | Which parser to use. |

*.scss

| Option | value | Description | | :---------- | :---- | :------------------------------------------ | | parser | scss | Which parser to use. | | singleQuote | false | Use single quotes instead of double quotes. |

*.{ts,tsx}

| Option | value | Description | | :----- | :--------- | :------------------- | | parser | typescript | Which parser to use. |

*.vue

| Option | value | Description | | :----- | :---- | :------------------- | | parser | vue | Which parser to use. |

*.{yaml,yml}

| Option | value | Description | | :---------- | :---- | :------------------------------------------ | | parser | yaml | Which parser to use. | | singleQuote | false | Use single quotes instead of double quotes. |