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

eslint-flat-config-react

v1.0.1

Published

A set of opinionated ESLint rules (all rules included) tailored for React projects using Eslint's flat configuration format.

Downloads

141

Readme

eslint-flat-config-react

A set of opinionated ESLint (http://eslint.org) rules (all rules included) tailored for React projects using Eslint's flat configuration format (http://eslint.org/docs/user-guide/configuring#using-a-configuration-file).

Usage:

  1. npm install --save-dev eslint-config-react babel-eslint eslint-plugin-react
  2. Create a file named .eslintrc in your project:
{
  "extends": "react"
  // Your overrides...
}

Why does it complain about bla-blu-blä, what does it all mean?

Read about all the rules here: http://eslint.org/docs/rules/
React plugin rules: https://github.com/yannickcr/eslint-plugin-react#list-of-supported-rules

Changelog

1.1.2

Removed a bunch of rules about method order, especially the ones that is not really relevant with ES6 anymore

1.1.1

Removed env from config. That should be set per project, especially since it can't be overriden.

1.1.0

arrow-parens: You should be allowed to omit parens if only one parameter (2 -> 0)
prefer-spread: Moving to ES6, this should be default.
prefer-reflect: Moving to ES6, this should be default.
react/forbid-prop-types: Forbid the usage of React.PropTypes.any, it doesn't say anything really.
react/jsx-closing-bracket-location: Don't care
react/jsx-indent-props: Don't specify any.
react/jsx-quotes: Again don't care, altho I thin "" makes more sense react/no-direct-mutation-state: If you do this, you should be sent to React prison :)
react/no-set-state: Entirely project specific.

1.0.5

react/sort-comp: Order custom component* (lifecycle) methods before other custom methods.

1.0.4

prefer-const: Disabled since it's very annoying when you have variables that will be changeable later on. const is a very nice concept that should be used for stuff that are actually constants.

1.0.3

Name change. This is a config for React projects.

1.0.2

jsx-quotes: The react/jsx-quotes rule is deprecated. Using the jsx-quotes rule instead.

1.0.1

no-unused-vars: Ignore React as unused variable. Because you need to import React for JSX (it will reference that variable) without you specifically referencing it.