zuke.tools.tsx
@zuke/tsx 1.0.1: @zuke/tsx — typed tsx task wrappers for Zuke builds.
zuke on PyPI ↗ 4 symbols
Symbols
class TsxCommonSettings(ToolSettings) Options shared by every tsx invocation: the entry point and how to load it.
-
script(path: str) -> SelfThe entry point to execute (required).
-
script_args(*args: str | float) -> SelfArguments passed to the script (after the entry point).
-
tsconfig(path: str) -> SelfUse an explicit
tsconfig.json(--tsconfig). -
env_file(path: str) -> SelfLoad environment variables from a file (
--env-file). -
no_cache() -> SelfDisable the file-system transpile cache (
--no-cache). -
no_warnings() -> SelfSuppress Node warnings (
--no-warnings). -
conditions(*names: str) -> SelfCustom export conditions to resolve (
--conditions); repeatable. -
import_module(*modules: str) -> SelfPreload a module before the entry point (
--import); repeatable.
class TsxSettings(TsxCommonSettings) Settings for tsx <file>.
class TsxTasks Typed task functions for the tsx TypeScript runner.
-
static async tsx(ctx: ServiceContext, configure: Callable[[TsxSettings], TsxSettings] | None=None) -> ExecResultRun a TypeScript entry point:
tsx <file>. -
static async watch(ctx: ServiceContext, configure: Callable[[TsxWatchSettings], TsxWatchSettings] | None=None) -> ExecResultRe-run an entry point on changes:
tsx watch <file>.
class TsxWatchSettings(TsxCommonSettings) Settings for tsx watch <file>.
-
no_clear_screen() -> SelfKeep prior output between reruns (
--clear-screen=false). -
include(*paths: str) -> SelfAdditional paths to watch (
--include); repeatable. -
exclude(*paths: str) -> SelfPaths to ignore while watching (
--exclude); repeatable.