1 | import { RawAbbreviatedPackument } from '../types/raw-abbreviated-packument';
|
2 | /**
|
3 | * `getRawAbbreviatedPackument` returns the abbreviated packument (package document)
|
4 | * containing only the metadata necessary to install a package present on the registry.
|
5 | *
|
6 | * Note: the abbreviated packument is returned as retrieved from the registry.
|
7 | *
|
8 | * @param name - package name
|
9 | * @param registry - URL of the registry (default: npm registry)
|
10 | * @param mirrors - URLs of the registry mirrors (default: npm registry mirrors)
|
11 | * @param cached - accept cached responses (default: `true`)
|
12 | *
|
13 | * @example
|
14 | * Get the abbreviated packument for package `query-registry` from the npm registry:
|
15 | *
|
16 | * ```typescript
|
17 | * import { getRawAbbreviatedPackument } from 'query-registry';
|
18 | *
|
19 | * (async () => {
|
20 | * const packument = await getRawAbbreviatedPackument({ name: 'query-registry' });
|
21 | *
|
22 | * // Output: 'query-registry'
|
23 | * console.log(packument.name);
|
24 | * })();
|
25 | * ```
|
26 | *
|
27 | * @see {@link RawAbbreviatedPackument}
|
28 | * @see {@link npmRegistry}
|
29 | * @see {@link npmRegistryMirrors}
|
30 | */
|
31 | export declare function getRawAbbreviatedPackument({ name, registry, mirrors, cached, }: {
|
32 | name: string;
|
33 | registry?: string;
|
34 | mirrors?: string[];
|
35 | cached?: boolean;
|
36 | }): Promise<RawAbbreviatedPackument>;
|
37 | //# sourceMappingURL=get-raw-abbreviated-packument.d.ts.map |
\ | No newline at end of file |