From b22c28eac9d8bce4c745101df63e25fa795c651e Mon Sep 17 00:00:00 2001 From: "J. Ryan Stinnett" Date: Fri, 18 Dec 2020 14:49:28 +0000 Subject: [PATCH] Use TypeScript source for development, swap to build during release This changes the JS SDK to point `main` to TypeScript source and remove any indication of `typings`. For local development and CI workflows, it means many steps can run without building first, which saves lots of time. During release, we still build for Node and browsers as before. The release script adjusts the `main` and `typings` fields before publishing and distribution to point to the built output for those that use them. --- package.json | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index b30b430a62..a3443af38b 100644 --- a/package.json +++ b/package.json @@ -27,9 +27,10 @@ "matrix-gen-i18n": "scripts/gen-i18n.js", "matrix-prune-i18n": "scripts/prune-i18n.js" }, - "main": "./lib/index.js", - "typings": "./lib/index.d.ts", + "main": "./src/index.js", "matrix_src_main": "./src/index.js", + "matrix_lib_main": "./lib/index.js", + "matrix_lib_typings": "./lib/index.d.ts", "scripts": { "prepublishOnly": "yarn build", "i18n": "matrix-gen-i18n",