NPM.Monorepo (NPM v0.6.0)

Copy Markdown View Source

Detects monorepo tooling and structure.

Identifies which monorepo tool is in use (npm workspaces, lerna, turborepo, nx, rush) and provides workspace discovery.

Summary

Functions

Detects the monorepo tool in use.

Formats detection results.

Returns monorepo metadata.

Checks if the project is a monorepo.

Returns the primary monorepo tool.

Functions

detect(project_dir \\ ".")

@spec detect(String.t()) :: [atom()]

Detects the monorepo tool in use.

format_info(map)

@spec format_info(map()) :: String.t()

Formats detection results.

info(project_dir \\ ".")

@spec info(String.t()) :: map()

Returns monorepo metadata.

monorepo?(project_dir \\ ".")

@spec monorepo?(String.t()) :: boolean()

Checks if the project is a monorepo.

primary(project_dir \\ ".")

@spec primary(String.t()) :: atom() | nil

Returns the primary monorepo tool.