Documentation for Simbo's Packages
    Preparing search index...

    Function getWorkspacePatterns

    • Get the workspaces patterns from the specified working directory.

      Assuming the given working directory is a monorepo, this function will return the patterns for all workspaces defined for the monorepo.

      If it finds workspaces defined in one of these places, it will return them and look no further:

      • in ./pnpm-workspace.yaml file at packages
      • in ./package.json files at workspaces

      The found patterns are not trimmed and filtered for empty strings. Beyond that, they are not parsed or validated in any way.

      Parameters

      Returns Promise<string[]>

      An array of workspace patterns.

      If no configuration files are found, configurations didn't provide any patterns or if there is an error reading the configuration files.