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

@lnu/eslint-config

v2.0.11

Published

ESLint shareable config with JSDoc rules and modern best practices.

Readme

📘 @lnu/eslint-config

A modular ESLint Flat Config for JavaScript with optional TypeScript and test framework extensions (Jest, Mocha). Designed for educational use at Linnaeus University.

This package provides a strict, explicit, and composable linting system based on ESLint Flat Config.

⚡ Requirements

  • Node.js >= 20
  • ESLint >= 10 (Flat Config only)
  • ESM ("type": "module" in package.json)

📦 Installation

Base setup (JavaScript only)

npm install -D @lnu/eslint-config
npm install -D @eslint/js @stylistic/eslint-plugin eslint eslint-plugin-jsdoc eslint-plugin-n eslint-plugin-regexp eslint-plugin-security globals

Usage

// eslint.config.js
import config from '@lnu/eslint-config';

export default config;

🧱 Architecture

This configuration is built using explicit composition.

It consists of:

  • Base config (always included)
  • Optional extension layers
    • TypeScript (/ts)

Composition model

import config from '@lnu/eslint-config';
import { tsRules } from '@lnu/eslint-config/ts';

export default [...config, ...tsRules];

No implicit configuration layering exists. All optional extensions must be explicitly imported.

📦 Core peer dependencies (always required)

These must be installed in the consuming project because ESLint Flat Config does not resolve plugins automatically.

@eslint/js
@stylistic/eslint-plugin
eslint
eslint-plugin-jsdoc
eslint-plugin-n
eslint-plugin-regexp
eslint-plugin-security
globals

🧩 Optional peer dependencies

TypeScript

@typescript-eslint/parser
@typescript-eslint/eslint-plugin

🧩 Optional extensions

These are only required if you use the corresponding layer.

🟦 TypeScript

npm install -D @typescript-eslint/parser @typescript-eslint/eslint-plugin
import config from '@lnu/eslint-config';
import { tsRules } from '@lnu/eslint-config/ts';

export default [...config, ...tsRules];

🚫 Not included

This package intentionally does NOT include:

  • Prettier or formatting tools
  • Framework configs (React, Vue, etc.)
  • Test frameworks by default
  • Legacy .eslintrc support

All optional concerns must be explicitly added.

📦 Exports

@lnu/eslint-config
@lnu/eslint-config/ts

🧭 Design principles

  • Explicit over implicit
  • Composition over inheritance
  • No hidden dependencies
  • Minimal default surface area
  • Opt-in complexity only

🧪 Testing (optional setup)

This configuration does not include built-in test framework integrations.

Test frameworks (Jest, Vitest, Mocha) are user-owned concerns and can be integrated using ESLint flat config overrides with globals and file patterns.


✔️ Recommended setup (framework-agnostic)

Config

import config from '@lnu/eslint-config';
import globals from 'globals';

export default [
  ...config,
  {
    files: ['**/*.test.js', '**/*.spec.js', '**/__tests__/**/*.js'],
    languageOptions: {
      globals: {
        ...globals.jest,
      },
    },
  },
];

🧠 Optional note

If you want framework-specific lint rules (e.g. Jest plugin rules), you can install and configure the corresponding ESLint plugin in your project.

This package does not include or depend on any test framework plugins.

⚙️ Prettier

This ESLint configuration does not include or depend on any formatting system.

Prettier is supported as an optional, standalone code formatter that runs independently of ESLint.

Installation

Prettier is not required by this configuration.

npm install -D prettier

Optional ESLint compatibility layer

If your project uses ESLint rules that conflict with Prettier formatting rules, you may optionally install eslint-config-prettier.

npm install -D eslint-config-prettier

If used, it must be placed last in the ESLint flat config:

import config from '@lnu/eslint-config';
import prettier from 'eslint-config-prettier';

export default [...config, prettier];

Note: Only relevant if your ESLint setup includes formatting-related rules that would otherwise conflict with Prettier.

📊 Summary

| Feature | Included | | ---------- | ----------- | | JavaScript | ✔ | | Node.js | ✔ | | Security | ✔ | | Regexp | ✔ | | JSDoc | ✔ | | TypeScript | ➕ (opt-in) |