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

eslint-config-mocg

v2.2.0

Published

Shared, company-wide ESLint flat config for Node.js, NestJS, React, Next.js, and Vue projects — with an interactive installer.

Readme

eslint-config-mocg

The shared, company-wide ESLint flat config for Node.js, NestJS, React, Next.js, and Vue — with a one-command installer.

A single, versioned package that encodes one strict standard for our TypeScript and JavaScript. Core plugins ship bundled and version-locked; framework plugins load on demand. Adopt it in one command, govern it in one place.

Quick start

npx eslint-config-mocg init

This detects your framework and package manager, installs what you need, writes eslint.config.mjs, and adds lint scripts. Or do it manually:

npm i -D eslint-config-mocg eslint
// eslint.config.mjs
import { mocg } from 'eslint-config-mocg';

export default mocg(); // auto-detects your stack
npm run lint

What it covers

  • Stacks: Node/TypeScript (base), NestJS, React, Next.js (= React + Next), Vue
  • Add-ons: Vite (React Fast Refresh), Vitest, Jest, Zod, i18next, Tailwind CSS
  • Out of the box: type-aware TS linting, import hygiene, security rules, naming conventions, Prettier integration, dead-code detection, and more — see the rules reference.

Examples

Five runnable example consumers live in examples/ — each installs the packed tarball and lints with a bare export default mocg() (Vue opts into type-aware SFCs with mocg({ vueTs: true })):

| Example | Stack | | --- | --- | | typescript-app | Node + TypeScript, path aliases, layered architecture | | react-app | React 19 + TypeScript (JSX runtime) | | next-app | Next.js 16 — App Router + Pages Router, Route Handler, 'use client' | | nest-app | NestJS — decorators, class-validator DTOs, Swagger | | vue-app | Vue 3 <script setup lang="ts"> single-file components |

They double as living documentation and as a verification gate: npm run verify:examples installs the freshly-packed config into each one and runs its lint + typecheck, so a rule or plugin that breaks in a real consumer install fails loudly. The husky pre-push hook runs it locally before every push.

Installing without a public registry

Until it's published to a registry, install from Git or a tarball. The package is authored in TypeScript and builds itself on install via the prepare script (npm installs the build's devDependencies and compiles dist/ automatically):

// git dependency — `prepare` compiles dist/ on install
"eslint-config-mocg": "git+ssh://[email protected]/moc-global/eslint-config.git#semver:^2"
# or a packed tarball (the tarball ships the prebuilt dist/)
npm run build && npm pack && npm i -D ./eslint-config-mocg-2.2.0.tgz

Once published, the registry tarball ships the prebuilt dist/ (with .d.ts), so consumers need no build step.

Adopting in an existing codebase

Don't fix everything at once. Baseline existing violations and ratchet down:

npx eslint-config-mocg init
npx eslint --suppress-all      # CI green today; only new violations fail

See Existing & legacy projects.

Documentation

📖 Published: moc-global.github.io/eslint-config — deployed from main by .github/workflows/docs.yml (live once GitHub Pages is enabled with Source: "GitHub Actions").

Or run it locally (npm run docs:dev). Start with:

Development

npm install              # legacy-peer-deps; `prepare` builds dist/ and installs husky git hooks
npm run build            # tsc → dist/*.js + *.d.ts
npm run lint             # the config lints its own TypeScript source
npm run typecheck
npm run test:run         # vitest — includes the React/Nest/Vue dogfood tests
npm run verify:examples  # install the packed config into examples/* and lint each
npm run docs:dev

All checks run locally via a husky pre-push hook before every push: lint + typecheck + test:run (whose dogfood tests compose mocg() for each stack and lint a fixture) + docs:build + pack:check + verify:examples. The checks workflow (.github/workflows/ci.yml) is kept on hand but disabled for now (manual-only); the docs deploy (.github/workflows/docs.yml) is the one active workflow. Use git push --no-verify to skip the hook for a one-off push.

License

MIT — Master of Code Global. Maintained by Dmytro Vakulenko.