diff --git a/package.json b/package.json index e5721b4..922b56d 100644 --- a/package.json +++ b/package.json @@ -2,10 +2,20 @@ "name": "tap-sdk-js", "version": "1.0.0", "description": "", - "main": "index.js", + "exports": "dist/index.js", "scripts": { "build": "tsc", - "test": "node --experimental-vm-modules node_modules/jest/bin/jest.js" + "test": "node --experimental-vm-modules node_modules/jest/bin/jest.js", + "prepublishOnly": "tsc" + }, + "files": "dist", + "main": "./dist/index.js", + "types": "./dist/index.d.ts", + "exports": { + ".": { + "import": "./dist/index.js", + "types": "./dist/index.d.ts" + } }, "keywords": [], "author": "minco", diff --git a/test/blah.test.ts b/test/blah.test.ts index 5b410c9..0de651b 100644 --- a/test/blah.test.ts +++ b/test/blah.test.ts @@ -1,4 +1,4 @@ -import { createClient } from "../src/core/client.js"; +import { createClient } from "../src/index.js"; describe("blah", () => { test("works", async () => {