-
Notifications
You must be signed in to change notification settings - Fork 0
/
web_app_entries_def.ts
44 lines (40 loc) · 1.24 KB
/
web_app_entries_def.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 { MessageDescriptor, PrimitiveType } from '@selfage/message/descriptor';
export interface WebAppEntry {
/* The source TypeScript file, relative to the directory of the config file. File ext can be neglected. */
source?: string,
/* The output file name after bundling, relative to the directory of the config file. File ext can be neglectd. A JS file and an HTML file are expected to be generated. */
output?: string,
}
export let WEB_APP_ENTRY: MessageDescriptor<WebAppEntry> = {
name: 'WebAppEntry',
fields: [
{
name: 'source',
primitiveType: PrimitiveType.STRING,
},
{
name: 'output',
primitiveType: PrimitiveType.STRING,
},
]
};
export interface WebAppEntries {
entries?: Array<WebAppEntry>,
/* Extra asset files that need to be copied to and served from a new directory, such as favicon.ico. Asset files that are imported by entry files don't need to be included here. */
extraAssets?: Array<string>,
}
export let WEB_APP_ENTRIES: MessageDescriptor<WebAppEntries> = {
name: 'WebAppEntries',
fields: [
{
name: 'entries',
messageType: WEB_APP_ENTRY,
isArray: true
},
{
name: 'extraAssets',
primitiveType: PrimitiveType.STRING,
isArray: true
},
]
};