forked from argentlabs/starknetkit
-
Notifications
You must be signed in to change notification settings - Fork 0
/
vite.config.ts
41 lines (39 loc) · 953 Bytes
/
vite.config.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import { resolve } from "path"
import { svelte } from "@sveltejs/vite-plugin-svelte"
import { defineConfig } from "vite"
import dts from "vite-plugin-dts"
// https://vitejs.dev/config/
export default defineConfig({
build: {
rollupOptions: {
external: ["starknet"],
},
emptyOutDir: false,
target: "es2020",
lib: {
entry: {
starknetkit: resolve(__dirname, "src/main.ts"),
webwalletConnector: resolve(
__dirname,
"src/connectors/webwallet/index.ts",
),
argentMobile: resolve(
__dirname,
"src/connectors/argentMobile/index.ts",
),
injectedConnector: resolve(
__dirname,
"src/connectors/injected/index.ts",
),
},
formats: ["es", "cjs"],
},
},
plugins: [
svelte({ emitCss: false }),
dts({
entryRoot: resolve(__dirname, "src"),
insertTypesEntry: true,
}),
],
})