From 9f2b668f5d908a1cfbacd2d97d326aad5ce3db44 Mon Sep 17 00:00:00 2001 From: Scott Phillips Date: Mon, 1 Aug 2022 16:27:21 -0400 Subject: [PATCH] Export `@trinsic/sdk/browser` properly (#906) --- web/README.md | 6 +++--- web/package.json | 6 +++++- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/web/README.md b/web/README.md index 810986f82..bfd2f6db3 100644 --- a/web/README.md +++ b/web/README.md @@ -2,18 +2,18 @@ ## Installation ```bash -npm install @trinsic/trinsic +npm install @trinsic/sdk ``` ```ts import { TrinsicService -} from "@trinsic/trinsic"; +} from "@trinsic/sdk"; ``` For bundlers that do not use the `"browser"` field, you can directly import the required web package with: ```ts -import { AccountService} from "@trinsic/trinsic/lib/browser"; +import { AccountService} from "@trinsic/sdk/browser"; ```` ## Documentation diff --git a/web/package.json b/web/package.json index 51914ebdd..a2d4df039 100644 --- a/web/package.json +++ b/web/package.json @@ -1,5 +1,5 @@ { - "name": "@trinsic/trinsic", + "name": "@trinsic/sdk", "version": "1.0.0", "description": "Node and Browser wrapper for the Trinsic services", "browser": { @@ -10,6 +10,10 @@ "files": [ "lib/**/*" ], + "exports": { + ".": "./lib/index.js", + "./browser": "./lib/browser.js" + }, "scripts": { "build": "npm run build:proto && npm run build:typescript", "build:proto": "pwsh Generate-Proto.ps1",