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 🙏

© 2026 – Pkg Stats / Ryan Hefner

@lunit/eslint-config

v2.0.0

Published

Lunit ESLint Config

Readme

@lunit/eslint-config

A TypeScript ESLint ruleset designed for Lunit projects based on @rushstack/eslint-config.

This ESLint configuration is only available for TypeScript projects.

Installation

npm install --save-dev @lunit/eslint-config

Usage

Getting Started

@lunit/eslint-config v2.x is configured using the ESLint Flat Config approach.

For information regarding ESLint Flat Config, please refer to the relevant ESLint Blog post.

  • https://eslint.org/blog/2022/08/new-config-system-part-2/

To use it, add @lunit/eslint-config to your eslint.config.js file as follows. If you are using TypeScript ESLint rules, please remove them. This is already being used in Rushstack ESLint, causing conflict issues.

ESM

// eslint.config.js
import js from "@eslint/js";
import globals from "globals";
import reactHooks from "eslint-plugin-react-hooks";
import reactRefresh from "eslint-plugin-react-refresh";
import { defineConfig, globalIgnores } from "eslint/config";
import eslintConfig from '@lunit/eslint-config';

export default defineConfig([
  globalIgnores(["dist"]),
  {
    files: ["**/*.{ts,tsx}"],
    extends: [
      js.configs.recommended,
      reactHooks.configs.flat["recommended-latest"],
      reactRefresh.configs.vite,
    ],
    languageOptions: {
      ecmaVersion: 2020,
      globals: globals.browser,
    },
  },
  lunitEslintConfig,
]);

CommonJS

// eslint.config.cjs
const js = require("@eslint/js");
const  globals = require("globals");
const reactHooks = require("eslint-plugin-react-hooks");
const reactRefresh = require("eslint-plugin-react-refresh");
const { defineConfig, globalIgnores } = require("eslint/config");
const lunitEslintConfig = require('@lunit/eslint-config');

module.exports = defineConfig([
  globalIgnores(["dist"]),
  {
    files: ["**/*.{ts,tsx}"],
    extends: [
      js.configs.recommended,
      reactHooks.configs.flat["recommended-latest"],
      reactRefresh.configs.vite,
    ],
    languageOptions: {
      ecmaVersion: 2020,
      globals: globals.browser,
    },
  },
  // You can add the ESLint Config rules as follows.
  lunitEslintConfig,
]);

If you created the app using vite, please refer to the information below.

If the tsconfig.json file is separate and the actual rules are applied in tsconfig.app.json, please configure it as follows.

rushstack eslint config internally follows the rules set in tsconfig, so you must link the corresponding JSON file.

ESM

// eslint.config.js
import js from "@eslint/js";
import globals from "globals";
import reactHooks from "eslint-plugin-react-hooks";
import reactRefresh from "eslint-plugin-react-refresh";
import { defineConfig, globalIgnores } from "eslint/config";
import eslintConfig from '@lunit/eslint-config';

export default defineConfig([
  globalIgnores(["dist"]),
  {
    files: ["**/*.{ts,tsx}"],
    extends: [
      js.configs.recommended,
      reactHooks.configs.flat["recommended-latest"],
      reactRefresh.configs.vite,
    ],
    languageOptions: {
      ecmaVersion: 2020,
      globals: globals.browser,
    },
  },
  {
    ...eslintConfig,
    // You must integrate the tsconfig.app.json file applied to the actual ts and tsx files as shown below.
    languageOptions: {
      parserOptions: {
        project: ["./tsconfig.app.json"],
        tsconfigRootDir: import.meta.dirname,
      },
    },
  }
]);

CommonJS

// eslint.config.cjs
const js = require("@eslint/js");
const  globals = require("globals");
const reactHooks = require("eslint-plugin-react-hooks");
const reactRefresh = require("eslint-plugin-react-refresh");
const { defineConfig, globalIgnores } = require("eslint/config");
const lunitEslintConfig = require('@lunit/eslint-config');

module.exports = defineConfig([
  globalIgnores(["dist"]),
  {
    files: ["**/*.{ts,tsx}"],
    extends: [
      js.configs.recommended,
      reactHooks.configs.flat["recommended-latest"],
      reactRefresh.configs.vite,
    ],
    languageOptions: {
      ecmaVersion: 2020,
      globals: globals.browser,
    },
  },
  {
    ...lunitEslintConfig,
    // You must integrate the tsconfig.app.json file applied to the actual ts and tsx files as shown below.
    languageOptions: {
      parserOptions: {
        project: ["./tsconfig.app.json"],
        tsconfigRootDir: __dirname,
      },
    },
  }
]);

Advanced

Override rushstack eslint rule

If you wish to modify the Rushstack ESLint rule, please refer to the code below.

ESM

// eslint.config.js
import js from "@eslint/js";
import globals from "globals";
import reactHooks from "eslint-plugin-react-hooks";
import reactRefresh from "eslint-plugin-react-refresh";
import { defineConfig, globalIgnores } from "eslint/config";
import eslintConfig from '@lunit/eslint-config';

export default defineConfig([
  globalIgnores(["dist"]),
  {
    files: ["**/*.{ts,tsx}"],
    extends: [
      js.configs.recommended,
      reactHooks.configs.flat["recommended-latest"],
      reactRefresh.configs.vite,
    ],
    languageOptions: {
      ecmaVersion: 2020,
      globals: globals.browser,
    },
  },
  {
    // Using Spread Operator lunit Eslint Config
    ...lunitEslintConfig,
    rules: {
      // Using Spread Operator lunit Eslint Config Rules
      ...lunitEslintConfig.rules,
      // And apply the target rule
      '@rushstack/no-new-null': 'error',
    },
  }
]);

CommonJS

// eslint.config.cjs
const js = require("@eslint/js");
const  globals = require("globals");
const reactHooks = require("eslint-plugin-react-hooks");
const reactRefresh = require("eslint-plugin-react-refresh");
const { defineConfig, globalIgnores } = require("eslint/config");
const lunitEslintConfig = require('@lunit/eslint-config');

module.exports = defineConfig([
  globalIgnores(["dist"]),
  {
    files: ["**/*.{ts,tsx}"],
    extends: [
      js.configs.recommended,
      reactHooks.configs.flat["recommended-latest"],
      reactRefresh.configs.vite,
    ],
    languageOptions: {
      ecmaVersion: 2020,
      globals: globals.browser,
    },
  },
  {
    // Using Spread Operator lunit Eslint Config
    ...lunitEslintConfig,
    rules: {
      // Using Spread Operator lunit Eslint Config Rules
      ...lunitEslintConfig.rules,
      // And apply the target rule
      '@rushstack/no-new-null': 'error',
    },
  }
]);

Migrate 1.x to 2.x

Since migration to the ESLint flat config is required, please refer to the official ESLint documentation guide below.

  • https://eslint.org/docs/latest/use/configure/migration-guide