From d03e48b4bdb7576d2d74ead7765dd11fc5f03c99 Mon Sep 17 00:00:00 2001 From: Natalie Weizenbaum Date: Mon, 16 Oct 2023 17:28:42 -0700 Subject: [PATCH] Try again to properly locate the TypeScript types --- package.json | 4 ++-- tool/prepare-release.ts | 5 +---- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index 003e3895..fc1cc395 100644 --- a/package.json +++ b/package.json @@ -12,8 +12,8 @@ "types": "./dist/types/index.m.d.ts", "default": "./dist/lib/index.mjs" }, - "types": "./dist/lib/index.d.ts", - "default": "./dist/types/index.js" + "types": "./dist/types/index.d.ts", + "default": "./dist/lib/index.js" }, "main": "dist/lib/index.js", "types": "dist/types/index.d.ts", diff --git a/tool/prepare-release.ts b/tool/prepare-release.ts index 44c8847e..d5d3ba0d 100644 --- a/tool/prepare-release.ts +++ b/tool/prepare-release.ts @@ -17,13 +17,10 @@ void (async () => { console.log('Transpiling TS into dist.'); shell.exec('tsc -p tsconfig.build.json'); shell.cp('lib/index.mjs', 'dist/lib/index.mjs'); - shell.cp( - 'dist/lib/src/vendor/sass/index.d.ts', - 'dist/lib/src/vendor/sass/index.m.d.ts' - ); console.log('Copying JS API types to dist.'); shell.cp('-R', 'lib/src/vendor/sass', 'dist/types'); + shell.cp('dist/types/index.d.ts', 'dist/types/index.m.d.ts'); await fs.unlink('dist/types/README.md'); console.log('Ready for publishing to npm.');