interface PackageData {
    data: {
        browser: string | Record<string, string | false>;
        dependencies: Record<string, string>;
        exports: string | string[] | Record<string, any>;
        imports: Record<string, any>;
        main: string;
        module: string;
        name: string;
        type: string;
        version: string;
        [field: string]: any;
    };
    dir: string;
    getResolvedCache: ((key, targetWeb) => undefined | string);
    hasSideEffects: ((id) => null | boolean | "no-treeshake");
    nodeResolvedImports: Record<string, undefined | string>;
    setResolvedCache: ((key, entry, targetWeb) => void);
    webResolvedImports: Record<string, undefined | string>;
}

Properties

data: {
    browser: string | Record<string, string | false>;
    dependencies: Record<string, string>;
    exports: string | string[] | Record<string, any>;
    imports: Record<string, any>;
    main: string;
    module: string;
    name: string;
    type: string;
    version: string;
    [field: string]: any;
}

Type declaration

  • [field: string]: any
  • browser: string | Record<string, string | false>
  • dependencies: Record<string, string>
  • exports: string | string[] | Record<string, any>
  • imports: Record<string, any>
  • main: string
  • module: string
  • name: string
  • type: string
  • version: string
dir: string
getResolvedCache: ((key, targetWeb) => undefined | string)

Type declaration

    • (key, targetWeb): undefined | string
    • Parameters

      • key: string
      • targetWeb: boolean

      Returns undefined | string

hasSideEffects: ((id) => null | boolean | "no-treeshake")

Type declaration

    • (id): null | boolean | "no-treeshake"
    • Parameters

      • id: string

      Returns null | boolean | "no-treeshake"

nodeResolvedImports: Record<string, undefined | string>
setResolvedCache: ((key, entry, targetWeb) => void)

Type declaration

    • (key, entry, targetWeb): void
    • Parameters

      • key: string
      • entry: string
      • targetWeb: boolean

      Returns void

webResolvedImports: Record<string, undefined | string>