Forked from https://github.com/azz/get-monorepo-packages
Get a list of packages from a monorepo. Upgraded to latest dependencies, modern ESM support (as at 2023-01-01) and adds Typescript and PNPM support.
Supports:
npm install --save list-monorepo-packages
import listPackages from 'list-monorepo-packages';
await getPackages('/path/to/root');
Returns an array of objects containing:
location
- The relative path to the package.package
- Thepackage.json
file for the package.