add support for optional mods

This commit is contained in:
cswimr 2025-02-08 09:28:18 -06:00
parent a74bafd3a1
commit f4e20ef240
Signed by: cswimr
GPG key ID: 0EC431A8DA8F8087

View file

@ -10,8 +10,15 @@ import {
export interface Metafile {
name: string;
filename: string;
side: "server" | "client" | "both";
side: "server" | "client" | "both" | undefined;
provider: UrlProvider;
option: Option;
}
export interface Option {
optional: boolean;
default?: boolean;
description?: string;
}
/**
@ -46,6 +53,11 @@ export class IndexFileEntry {
filename: parsed.filename,
side: parsed.side,
provider: this.parseProvider(parsed),
option: {
optional: parsed.option?.optional || false,
default: parsed.option?.default,
description: parsed.option?.description,
},
};
return metafile;