Home > @rushstack/package-deps-hash > getPackageDeps
getPackageDeps() function
Builds an object containing hashes for the files under the specified packagePath
folder.
Signature:
export declare function getPackageDeps(packagePath?: string, excludedPaths?: string[], gitPath?: string): Map<string, string>;
Parameters
Parameter | Type | Description |
---|---|---|
packagePath | string | (Optional) The folder path to derive the package dependencies from. This is typically the folder containing package.json. If omitted, the default value is the current working directory. |
excludedPaths | string[] | (Optional) An optional array of file path exclusions. If a file should be omitted from the list of dependencies, use this to exclude it. |
gitPath | string | (Optional) |
Returns:
Map<string, string>
the package-deps.json file content