o4b-formatter-typescript

0.1.0 • Public • Published

o4b-formatter-typescript

This package provides shared ESLint and Prettier configurations specifically for TypeScript projects. It is designed to ensure adherence to coding standards and consistent formatting across different projects.

Installation

Add the package to your project to enable uniform code formatting:

npm i -D o4b-formatter-typescript

Usage

After installation, you can reference the shared configurations in your project configuration files.

ESLint

Create a .eslintrc.json at the root of your project (or update the existing one) extending the configuration from o4b-formatter-typescript:

{
  "extends": [
    "./node_modules/o4b-formatter-typescript/eslint"
  ]
}

Prettier

Create a .prettierrc.json at the root of your project (or update the existing one) and import the configuration from o4b-formatter-typescript by adding only this one line:

"./node_modules/o4b-formatter-typescript/prettier.config"

Please note that this method does not offer a way to extend the configuration to overwrite some properties from the shared configuration. If you need to do that, please check the Prettier Documentation page.

Peer Dependencies

As of NPM version 7, peer dependencies are installed automatically. If you are using an older version of NPM and want to install all peer dependencies automatically, you can use install-peerdeps:

npx install-peerdeps o4b-formatter-typescript --dev

Make sure you have all the necessary peer dependencies installed to avoid compatibility issues.

Support and Feedback

If you have any questions or encounter issues with using o4b-formatter-typescript, please create an issue on the GitHub Issues page.

Visit the project homepage for more information and updates.

Package Sidebar

Install

npm i o4b-formatter-typescript

Weekly Downloads

0

Version

0.1.0

License

none

Unpacked Size

3.75 kB

Total Files

4

Last publish

Collaborators

  • mae-o4b