Type alias TraversalDataObj

    TraversalDataObj: {
        baseDir: string;
        cntr: number;
        currentDir: string;
        filepath: string;
        packageObj: object;
        relativeDir: string;
        rootPath: string;
    }

    Defines the data object passed to any traversal callback function. All paths are converted to Unix style paths, so for instance on Windows \ and \ are replaced with /.

    Type declaration

    • baseDir: string
      • Stores the basepath directory as a Unix styled path.
    • cntr: number
      • Stores the number of times a package.json has been processed.
    • currentDir: string
      • Current directory of traversal as a Unix styled path.
    • filepath: string
      • Current loaded package.json file path as a Unix styled path.
    • packageObj: object
      • Current loaded package.json object.
    • relativeDir: string
      • Current directory of traversal as a relative Unix styled path from process.cwd.
    • rootPath: string
      • The root path to stop traversal as a Unix styled path.