From e236cef37c69d1f4ecb0650c4e0e6e09afff2742 Mon Sep 17 00:00:00 2001 From: Nate Sesti Date: Tue, 19 Mar 2024 12:33:37 -0700 Subject: [PATCH] =?UTF-8?q?=F0=9F=93=A6=20package=20.js=20in=20npm=20packa?= =?UTF-8?q?ge?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- core/.npmignore | 2 ++ core/package.json | 3 ++- core/tsconfig.npm.json | 22 ++++++++++++++++++++++ 3 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 core/.npmignore create mode 100644 core/tsconfig.npm.json diff --git a/core/.npmignore b/core/.npmignore new file mode 100644 index 000000000..c2111fc33 --- /dev/null +++ b/core/.npmignore @@ -0,0 +1,2 @@ +.env +.vscode \ No newline at end of file diff --git a/core/package.json b/core/package.json index 184dd7a56..a058ceb75 100644 --- a/core/package.json +++ b/core/package.json @@ -3,7 +3,8 @@ "version": "1.0.1", "description": "The Continue Core contains functionality that can be shared across web, VS Code, or Node.js server. It is written in TypeScript and contains much of the functionality that was previously inside of the legacy Continue Python Server.", "scripts": { - "test": "jest ./test/diff.test.ts" + "test": "jest ./test/diff.test.ts", + "build:npm": "tsc -p ./tsconfig.npm.json" }, "author": "Nate Sesti and Ty Dunn", "license": "Apache-2.0", diff --git a/core/tsconfig.npm.json b/core/tsconfig.npm.json new file mode 100644 index 000000000..7a807f03f --- /dev/null +++ b/core/tsconfig.npm.json @@ -0,0 +1,22 @@ +{ + "compilerOptions": { + "target": "ESNext", + "useDefineForClassFields": true, + "lib": ["DOM", "DOM.Iterable", "ESNext", "ES2021"], + "allowJs": false, + "skipLibCheck": true, + "esModuleInterop": false, + "allowSyntheticDefaultImports": true, + "strict": true, + "forceConsistentCasingInFileNames": true, + "module": "ESNext", + "moduleResolution": "Node", + "resolveJsonModule": true, + "isolatedModules": true, + "jsx": "react-jsx", + "noEmitOnError": false, + "types": ["jest", "node"], + "outDir": "dist" + }, + "include": ["./**/*.ts", "indexing/embeddings/TransformersJsWorkerThread.js"] +}