Appearance
@loontail/minecraft-kit / MinecraftKitOptions
Type Alias: MinecraftKitOptions
ts
type MinecraftKitOptions = {
cache?: MetadataCache;
hostAllowList?: readonly string[];
httpClient?: HttpClient;
logger?: Logger;
spawner?: Spawner;
system?: RuntimeSystem;
};Defined in: src/kit.ts:53
Constructor options for MinecraftKit.
Example
ts
import { consoleLogger, MinecraftKit, type MinecraftKitOptions } from "@loontail/minecraft-kit";
const options: MinecraftKitOptions = { logger: consoleLogger };
const kit = new MinecraftKit(options);Properties
| Property | Modifier | Type | Description | Defined in |
|---|---|---|---|---|
cache? | readonly | MetadataCache | - | src/kit.ts:55 |
hostAllowList? | readonly | readonly string[] | Host allow-list applied to every install/repair file download. Download URLs come from network-fetched manifests, so pinning them to a known set of hosts closes a supply-chain MITM/manifest-rewrite vector. Defaults to DEFAULT_DOWNLOAD_HOST_ALLOWLIST (the Mojang/Fabric/Forge ecosystem). Entries support a leading wildcard label, e.g. "*.minecraft.net". Pass a custom list to add a private mirror. | src/kit.ts:66 |
httpClient? | readonly | HttpClient | - | src/kit.ts:54 |
logger? | readonly | Logger | - | src/kit.ts:56 |
spawner? | readonly | Spawner | - | src/kit.ts:58 |
system? | readonly | RuntimeSystem | - | src/kit.ts:57 |