From 20e13b3d96eb827cc7682b1341cb2fd82f0bd6b8 Mon Sep 17 00:00:00 2001 From: zhangxinxin <1285367184@qq.com> Date: Fri, 26 Jun 2026 17:29:35 +0800 Subject: [PATCH] fix: add `types` field to package.json for TypeScript support The package emits TypeScript declaration files (dist/milvus/index.d.ts) via `tsc --declaration` during build, but the package.json was missing the `types` field. As a result, TypeScript editors could not resolve types when importing from @zilliz/milvus2-sdk-node, even though the runtime worked correctly. This adds: ``` "types": "dist/milvus/index.d.ts" ``` Fixes the type resolution path so that `import { MilvusClient } from "@zilliz/milvus2-sdk-node"` provides full IntelliSense and type-checking in TypeScript projects. --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index 9f14699a..fce1c755 100644 --- a/package.json +++ b/package.json @@ -4,6 +4,7 @@ "milvusVersion": "v3.0-beta-amd64", "version": "3.0.3", "main": "dist/milvus", + "types": "dist/milvus/index.d.ts", "files": [ "dist" ],