/
types.ts
44 lines (39 loc) · 1009 Bytes
/
types.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
import type { PackageRule } from '../../../config/types';
import type { HostRule } from '../../../types';
import type { ReleaseResult } from '../types';
export interface NpmrcRules {
hostRules: HostRule[];
packageRules: PackageRule[];
}
export interface NpmResponseVersion {
repository?: {
url: string;
directory: string;
};
homepage?: string;
deprecated?: boolean;
gitHead?: string;
dependencies?: Record<string, string>;
devDependencies?: Record<string, string>;
engines?: Record<string, string>;
}
export interface NpmResponse {
_id: string;
name: string;
versions?: Record<string, NpmResponseVersion>;
repository?: {
url?: string;
directory?: string;
};
homepage?: string;
time?: Record<string, string>;
'dist-tags'?: Record<string, string>;
}
export interface CachedReleaseResult extends ReleaseResult {
cacheData?: {
revision?: number;
etag: string | undefined;
softExpireAt: string;
};
}
export type Npmrc = Record<string, any>;