hackmud-script-manager
Version:
Script manager for game hackmud, with minification, TypeScript support, and player script type definition generation.
16 lines (15 loc) • 986 B
TypeScript
import type { LaxPartial } from "@samual/lib";
import type { PushOptions } from "./push";
export type WatchOptions = PushOptions & LaxPartial<{
/** if provided, will write typescript type declarations for all the scripts on every change detected
*
* writing the type declarations enables interscript type checking and autocompletetes for the args */
typeDeclarationPath: string;
onReady: () => void;
rootFolderPath: string;
}>;
/** Watches target file or folder for updates and builds and pushes updated file.
* @param sourceDirectory path to folder containing source files
* @param hackmudDirectory path to hackmud directory
* @param options {@link WatchOptions details} and {@link PushOptions more details} */
export declare function watch(sourceDirectory: string, hackmudDirectory: string, { scripts, onPush, minify, mangleNames, typeDeclarationPath: typeDeclarationPath_, onReady, forceQuineCheats, rootFolderPath }?: WatchOptions): Promise<void>;