mirror of
https://github.com/ecomfe/vue-echarts.git
synced 2025-12-15 06:20:44 +08:00
feat!: inject style via constructable CSSStyleSheet and remove CSP entry (#847)
* chore: not inject inline css on server * feat!: remove csp entry * keep csp title in readme * chore: switch to rolldown and tsdown * update * dedupe * update according to review * emphasize "both" in csp section * load css with unplugin-raw * change tsdown entry
This commit is contained in:
32
tsdown.config.ts
Normal file
32
tsdown.config.ts
Normal file
@@ -0,0 +1,32 @@
|
||||
import { defineConfig } from "tsdown";
|
||||
import raw from "unplugin-raw/rollup";
|
||||
|
||||
export default defineConfig([
|
||||
{
|
||||
entry: "src/index.ts",
|
||||
platform: "browser",
|
||||
sourcemap: true,
|
||||
copy: ["src/style.css"],
|
||||
plugins: [raw()],
|
||||
},
|
||||
{
|
||||
entry: "src/global.ts",
|
||||
outputOptions: {
|
||||
file: "dist/index.min.js", // for unpkg/jsdelivr
|
||||
dir: undefined,
|
||||
format: "umd",
|
||||
name: "VueECharts",
|
||||
exports: "default",
|
||||
globals: {
|
||||
vue: "Vue",
|
||||
echarts: "echarts",
|
||||
"echarts/core": "echarts",
|
||||
},
|
||||
},
|
||||
platform: "browser",
|
||||
sourcemap: true,
|
||||
minify: true,
|
||||
dts: false,
|
||||
plugins: [raw()],
|
||||
},
|
||||
]);
|
||||
Reference in New Issue
Block a user