1.0.5 • Published 1 year ago

eslint-config-perxhealth v1.0.5

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

Perx Health

Build Status Build Status

Perx Health's standard, base ESLint configuration for Node and TypeScript projects. This package provides Perx's .eslintrc as an extensible, shared config.

Overview

Our config stands on the shoulders of existing, open source giants. We export (currently) a single entry point for all Node/JavaScript project types.

e.g. we currently make no distinction between a project in which React is present, whether TypeScript is present, etc...

Installation

We do not currently differentiate between React projects, ECMAScript 6+ projects etc... for now, it's one config to rule them all!

Use the below steps to install eslint-config-perxhealth in to your Node or JavaScript project.

Install ESLint and Prettier

Just in case you haven't done so already, you'll want eslint and prettier to be installed before attempting to use this config package.

$ pnpm install -D eslint prettier

Install Perx Config

Add the package from the npm registry with your package manager of choice.

$ pnpm install -D eslint-config-perxhealth

Or with yarn

$ yarn install -D eslint-config-perxhealth

Or with npm

$ npm install --save-dev eslint-config-perxhealth

Update ESLint Config

Configure your project's ESLint config to use the newly installed package. At Perx we prefer using .yaml files, but there's many ways to do so.

Create a file named .eslintrc.yaml.

extends: perxhealth

Or with JavaScript, create .eslintrc.js.

module.exports = {
  "extends": "perxhealth"
}

It is also possible to extend further, as is the nature of ESLint config.

Below is an example which starts with Airbnb's popular config and applies Perx's over the top.

extends:
  - airbnb
  - perxhealth

Maintenance or Development

Follow the below steps in sequence to get up and running with a local development copy of the package.

Prerequisites

You will need the following things properly installed on your machine.

Clone the repository

$ git clone git@github.com:perxhealth/eslint-config-perxhealth.git
$ cd eslint-config-perxhealth

Install System Dependencies

Use asdf to ensure the correct version of the package's system dependencies are installed and ready to use.

$ asdf install

Linting

Ensure this package lints against its own rules.

$ pnpm lint