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

@anarchitects/nx-governance

v0.11.0

Published

Nx governance plugin for workspace health, boundaries, ownership, and architecture reporting.

Readme

@anarchitects/nx-governance

Overview

@anarchitects/nx-governance is the Nx-facing Governance package. It runs Governance assessments for Nx workspaces and exposes results as CLI output, JSON, and report artifacts.

Use this package when you want to evaluate repository health, architecture boundaries, ownership signals, and dependency structure as part of local development or CI.

Key Concepts

  • Governance profiles define policy and reporting behavior for a workspace.
  • Nx executors expose Governance analyses as stable Nx targets.
  • Project Crystal inference can infer core governance targets from profile files.
  • The host package composes adapter extraction, extension contributions, and core evaluation.

Installation

yarn nx add @anarchitects/nx-governance

Quick Start

yarn nx repo-health
yarn nx repo-boundaries
yarn nx repo-ownership
yarn nx governance-graph

Architecture

@anarchitects/nx-governance is the composition root on the Nx side.

flowchart TD
  A[@anarchitects/nx-governance] --> B[@anarchitects/governance-adapter-nx]
  B --> C[@anarchitects/governance-core]
  D[@anarchitects/governance-extension-nx] --> C
  A --> C

More implementation-oriented architecture notes are available in ../../docs/architecture/governance-plugin-side-packages.md.

Responsibilities

This package owns:

  • Nx executors
  • Nx generators
  • Governance host runtime
  • profile loading
  • extension loading
  • report/output orchestration

This package does not own:

  • Nx metadata extraction
  • Governance rule evaluation internals
  • Governance metric calculation internals

Public API

Package entrypoints

  • @anarchitects/nx-governance (compatibility root export surface)
  • @anarchitects/nx-governance/host (host-owned TypeScript exports)
  • @anarchitects/nx-governance/plugin (Nx plugin inference entrypoint)

Nx generators

  • @anarchitects/nx-governance:init
  • @anarchitects/nx-governance:add-extension
  • @anarchitects/nx-governance:eslint-integration

Nx executors

  • @anarchitects/nx-governance:repo-health
  • @anarchitects/nx-governance:repo-boundaries
  • @anarchitects/nx-governance:repo-ownership
  • @anarchitects/nx-governance:repo-architecture
  • @anarchitects/nx-governance:repo-snapshot
  • @anarchitects/nx-governance:repo-drift
  • @anarchitects/nx-governance:repo-management-insights
  • @anarchitects/nx-governance:repo-ai-management-insights
  • @anarchitects/nx-governance:repo-ai-root-cause
  • @anarchitects/nx-governance:repo-ai-drift
  • @anarchitects/nx-governance:repo-ai-pr-impact
  • @anarchitects/nx-governance:repo-ai-cognitive-load
  • @anarchitects/nx-governance:repo-ai-recommendations
  • @anarchitects/nx-governance:repo-ai-smell-clusters
  • @anarchitects/nx-governance:repo-ai-refactoring-suggestions
  • @anarchitects/nx-governance:repo-ai-scorecard
  • @anarchitects/nx-governance:repo-ai-onboarding
  • @anarchitects/nx-governance:workspace-graph
  • @anarchitects/nx-governance:workspace-conformance
  • @anarchitects/nx-governance:governance-graph

Usage

Run as root-level inferred/explicit commands:

yarn nx repo-health --profile=frontend-layered
yarn nx repo-architecture --output=json --outputPath=dist/governance/repo-architecture.json
yarn nx governance-graph --format=html --outputPath=dist/governance/graph.html
yarn nx governance-graph --format=json --outputPath=dist/governance/graph.json

Use generator-driven setup and extension registration:

yarn nx g @anarchitects/nx-governance:init
yarn nx g @anarchitects/nx-governance:add-extension

Configuration

  • Profiles: tools/governance/profiles/*.json
  • Plugin inference option: profileGlob
  • Extension registration: nx.json and/or profile composition

Related Packages

  • @anarchitects/governance-core: canonical contracts and deterministic governance logic.
  • @anarchitects/governance-adapter-nx: Nx workspace extraction and canonical adapter mapping.
  • @anarchitects/governance-extension-nx: Nx-specific extension boundary for rules, metrics, and enrichers.

Compatibility

  • Peer dependencies: Nx >=19 and <23.
  • Designed for Nx workspaces that want governance checks integrated into normal Nx workflows.

FAQ

Should I install this package or only the adapter/extension package?

Install @anarchitects/nx-governance for end-user Nx workflows. It is the package that provides Nx commands, generators, and host orchestration.

Where are deeper internal implementation notes?

Use ../../docs/architecture/governance-plugin-side-packages.md and ../../docs/migration/governance-readme-internal-notes.md for internal architecture and migration-oriented details.

License

Apache-2.0