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 🙏

© 2025 – Pkg Stats / Ryan Hefner

eslint-plugin-fpcs

v2.0.0

Published

FPCS eslint plugin including configs and custom rules.

Downloads

189

Readme

eslint-plugin-fpcs

npm version npm (prod) eslint dependency version npm (prod) mocha dependency version npm bundle size npm downloads NPM License

FPCS eslint style rules.

Installation

  1. yarn add --dev eslint-plugin-fpcs
  2. Install peer dependencies. Most of the peer dependencies on this package are optional, only required for certain platforms.

Migrating from v1.x to v2.x

  1. Update your project's package.json devDependencies to use "eslint-plugin-fpcs": "^2.0.0"
  2. Run yarn
  3. Follow "Install peer dependencies" instruction from "Installation" section above.

💔 Breaking changes from v1.x

Babel has been split off into a separate config

If you use babel, you will need to add "plugin:fpcs/babel" to the extends section of your .eslintrc file. Make sure to place it directly after base, before any other configs like typescript or react.

prefer-default-export removed in favor of opposite no-default-export

FPCS has decided to move to always using named exports. See discussion in style guide.

To use v2 you will need to do one of the following:

  • Change all default exports to named exports in your codebase.
  • Add eslint-disable import/no-default-export for every default export in your codebase.
  • Add the following to your codebase's .eslintrc file:
rules: {
  'import/no-default-export': 'off',
  'import/prefer-default-export': 'warn',
  'no-restricted-exports': 'off',
}

Alternatively, you may stay on v1.x, but future updates may not be applied to the v1.x tree.

Usage

Add desired config sets to the extends section of your .eslintrc or .eslintrc.js configuration file.

Available configs:

  • plugin:fpcs/base
  • plugin:fpcs/babel
  • plugin:fpcs/react
  • plugin:fpcs/react-typescript
  • plugin:fpcs/typescript
  • plugin:fpcs/vue

JavaScript / ECMAScript

{
    "extends": [ "plugin:fpcs/base" ],
}

TypeScript

{
    "extends": [
        "plugin:fpcs/base",
        "plugin:fpcs/typescript",
    ],
}

React

{
    "extends": [
        "plugin:fpcs/base",
        "plugin:fpcs/react",
    ],
}

React TypeScript (automatically adds fpcs/react and fpcs/typescript)

{
    "extends": [
        "plugin:fpcs/base",
        "plugin:fpcs/react-typescript",
    ],
}

Vue

{
    "extends": [
        "plugin:fpcs/base",
        "plugin:fpcs/vue",
    ],
}

Babel

Typically used on a React app that gets transpiled by babel.

{
    "extends": [
        "plugin:fpcs/base",
        "plugin:fpcs/babel",
        ...if you extend other configs place them here, AFTER babel...
    ],
}

Add or modify individual rules:

Add desired config sets to the rules section of your .eslintrc or .eslintrc.js configuration file.

  "rules": {
    "@typescript-eslint/consistent-type-assertions": "off",
  },

Available Custom Rules

  • fpcs/no-gremlin-chars (automatically set to 'error' when using base config)
  • fpcs/prefer-early-return (automatically set to 'error' when using base config)

Development

To develop on this package, I strongly recommended that you use yalc. Yalc solves issues related to peer dependencies not symlinking correctly when using yarn link on local. Just run yalc publish in this repo and then yalc add eslint-plugin-fpcs && yarn in the user repo after every change.