From ae23d25e2a7e72b58c4dfe8a2d9c525a36d4aa19 Mon Sep 17 00:00:00 2001 From: Vitalij Ryndin Date: Fri, 6 Jan 2023 04:26:58 +0800 Subject: [PATCH] Add `jsdelivr` and `unpkg` meta --- packages/fireworks-js/package.json | 3 ++- packages/fireworks-js/src/fireworks.ts | 2 ++ packages/fireworks-js/src/vite-env.d.ts | 3 --- packages/fireworks-js/tsconfig.json | 6 ++++++ packages/preact/package.json | 3 ++- packages/react/package.json | 3 ++- packages/solid/package.json | 3 ++- packages/vue/package.json | 3 ++- packages/web/package.json | 3 ++- 9 files changed, 20 insertions(+), 9 deletions(-) delete mode 100644 packages/fireworks-js/src/vite-env.d.ts diff --git a/packages/fireworks-js/package.json b/packages/fireworks-js/package.json index 6813c31..5130f01 100644 --- a/packages/fireworks-js/package.json +++ b/packages/fireworks-js/package.json @@ -6,7 +6,8 @@ "homepage": "https://fireworks.js.org", "types": "./dist/index.d.ts", "main": "./dist/index.cjs.js", - "umd:main": "./dist/index.umd.js", + "jsdelivr": "./dist/index.umd.js", + "unpkg": "./dist/index.umd.js", "module": "./dist/index.es.js", "exports": { "require": "./dist/index.cjs.js", diff --git a/packages/fireworks-js/src/fireworks.ts b/packages/fireworks-js/src/fireworks.ts index acebe37..1b10227 100644 --- a/packages/fireworks-js/src/fireworks.ts +++ b/packages/fireworks-js/src/fireworks.ts @@ -8,6 +8,8 @@ import { Sound } from './sound.js' import { Trace } from './trace.js' import type { FireworksOptions, IBoundaries, Sizes } from './types.js' +declare const __VERSION__: string + export class Fireworks { private target: Element | HTMLCanvasElement private container: Element diff --git a/packages/fireworks-js/src/vite-env.d.ts b/packages/fireworks-js/src/vite-env.d.ts deleted file mode 100644 index 1540b75..0000000 --- a/packages/fireworks-js/src/vite-env.d.ts +++ /dev/null @@ -1,3 +0,0 @@ -/// - -declare const __VERSION__: string diff --git a/packages/fireworks-js/tsconfig.json b/packages/fireworks-js/tsconfig.json index 8eee9cc..a25dc2b 100644 --- a/packages/fireworks-js/tsconfig.json +++ b/packages/fireworks-js/tsconfig.json @@ -1,5 +1,11 @@ { "extends": "@crashmax/tsconfig", + "compilerOptions": { + "outDir": "dist", + "types": [ + "vite/client" + ] + }, "include": [ "src" ] diff --git a/packages/preact/package.json b/packages/preact/package.json index c625b1c..81f6f08 100644 --- a/packages/preact/package.json +++ b/packages/preact/package.json @@ -6,7 +6,8 @@ "homepage": "https://fireworks.js.org", "types": "./dist/index.d.ts", "main": "./dist/index.cjs.js", - "umd:main": "./dist/index.umd.js", + "jsdelivr": "./dist/index.umd.js", + "unpkg": "./dist/index.umd.js", "module": "./dist/index.es.js", "exports": { "require": "./dist/index.cjs.js", diff --git a/packages/react/package.json b/packages/react/package.json index 3ee4733..a022f9a 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -6,7 +6,8 @@ "homepage": "https://fireworks.js.org", "types": "./dist/index.d.ts", "main": "./dist/index.cjs.js", - "umd:main": "./dist/index.umd.js", + "jsdelivr": "./dist/index.umd.js", + "unpkg": "./dist/index.umd.js", "module": "./dist/index.es.js", "exports": { "require": "./dist/index.cjs.js", diff --git a/packages/solid/package.json b/packages/solid/package.json index 0a69712..bc7a9f4 100644 --- a/packages/solid/package.json +++ b/packages/solid/package.json @@ -6,7 +6,8 @@ "homepage": "https://fireworks.js.org", "types": "./dist/index.d.ts", "main": "./dist/index.cjs.js", - "umd:main": "./dist/index.umd.js", + "jsdelivr": "./dist/index.umd.js", + "unpkg": "./dist/index.umd.js", "module": "./dist/index.es.js", "exports": { "require": "./dist/index.cjs.js", diff --git a/packages/vue/package.json b/packages/vue/package.json index dbef9c1..efc796d 100644 --- a/packages/vue/package.json +++ b/packages/vue/package.json @@ -6,7 +6,8 @@ "homepage": "https://fireworks.js.org", "types": "./dist/index.d.ts", "main": "./dist/index.cjs.js", - "umd:main": "./dist/index.umd.js", + "jsdelivr": "./dist/index.umd.js", + "unpkg": "./dist/index.umd.js", "module": "./dist/index.es.js", "exports": { "require": "./dist/index.umd.js", diff --git a/packages/web/package.json b/packages/web/package.json index 06b814c..a979f0e 100644 --- a/packages/web/package.json +++ b/packages/web/package.json @@ -6,7 +6,8 @@ "homepage": "https://fireworks.js.org", "types": "./dist/index.d.ts", "main": "./dist/index.cjs.js", - "umd:main": "./dist/index.umd.js", + "jsdelivr": "./dist/index.umd.js", + "unpkg": "./dist/index.umd.js", "module": "./dist/index.es.js", "exports": { "require": "./dist/index.cjs.js",