diff --git a/packages/rust/src/executors/napi/executor.ts b/packages/rust/src/executors/napi/executor.ts index e961ea4..cb4c28b 100644 --- a/packages/rust/src/executors/napi/executor.ts +++ b/packages/rust/src/executors/napi/executor.ts @@ -22,6 +22,7 @@ export default async function runExecutor( buildOptions.platform = true; buildOptions.jsBinding = options.jsFile; + buildOptions.dts = options.dts; buildOptions.outputDir = options.dist; buildOptions.manifestPath = join(projectRoot ?? '.', 'Cargo.toml'); buildOptions.packageJsonPath = packageJson; diff --git a/packages/rust/src/executors/napi/schema.d.ts b/packages/rust/src/executors/napi/schema.d.ts index 61a6108..024281d 100644 --- a/packages/rust/src/executors/napi/schema.d.ts +++ b/packages/rust/src/executors/napi/schema.d.ts @@ -1,6 +1,7 @@ export interface NapiExecutorSchema { dist: string; jsFile: string; + dts?: string; release?: boolean; target?: string; zig?: boolean; diff --git a/packages/rust/src/executors/napi/schema.json b/packages/rust/src/executors/napi/schema.json index ba61755..b82517c 100644 --- a/packages/rust/src/executors/napi/schema.json +++ b/packages/rust/src/executors/napi/schema.json @@ -11,6 +11,10 @@ "jsFile": { "type": "string" }, + "dts": { + "type": "string", + "default": "index.d.ts" + }, "release": { "type": "boolean", "default": false