Skip to content

Commit

Permalink
Update wallet adapter vue (#412)
Browse files Browse the repository at this point in the history
* fix bundle size

* Bump @aptos-labs/wallet-adapter-core to 4.15.1

* fix version

* Bump @aptos-labs/wallet-adapter-core to 4.16.0

* changeset

---------

Co-authored-by: Maayan <maayan@aptoslabs.com>
  • Loading branch information
ildarH and 0xmaayan committed Sep 10, 2024
1 parent e954520 commit 3968a90
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 311 deletions.
5 changes: 5 additions & 0 deletions .changeset/few-foxes-sin.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@aptos-labs/wallet-adapter-vue": minor
---

Fix bundle size, bump @aptos-labs/wallet-adapter-core to 4.16.0
5 changes: 3 additions & 2 deletions packages/wallet-adapter-vue/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
"build": "pnpm build:bundle"
},
"dependencies": {
"@aptos-labs/wallet-adapter-core": "4.15.0"
"@aptos-labs/wallet-adapter-core": "4.16.0"
},
"devDependencies": {
"vite": "5.3.3",
Expand All @@ -53,7 +53,8 @@
"typescript": "^4.5.3",
"vue-tsc": "^2.0.26",
"vite-plugin-css-injected-by-js": "^3.5.1",
"rollup-plugin-typescript2": "^0.36.0"
"rollup-plugin-typescript2": "^0.36.0",
"vite-plugin-compression": "^0.5.1"
},
"peerDependencies": {
"vue": "^3.4.21"
Expand Down
8 changes: 7 additions & 1 deletion packages/wallet-adapter-vue/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import vue from "@vitejs/plugin-vue";
import dts from "vite-plugin-dts";
import typescript2, { RPT2Options } from "rollup-plugin-typescript2";
import cssInjectedByJsPlugin from "vite-plugin-css-injected-by-js";
import viteCompression from 'vite-plugin-compression';
import { resolve } from "path";

const typescript2Options: RPT2Options = {
Expand All @@ -27,6 +28,10 @@ export default defineConfig({
}),
cssInjectedByJsPlugin(),
typescript2({ ...typescript2Options }),
viteCompression({
algorithm: 'brotliCompress',
threshold: 10240,
}),
],
build: {
lib: {
Expand All @@ -38,14 +43,15 @@ export default defineConfig({
input: {
main: resolve(__dirname, "src/index.ts"),
},
external: ["vue"],
external: ["vue", "@aptos-labs/wallet-adapter-core"],
output: {
exports: "named",
globals: {
vue: "Vue",
},
},
},
minify: 'terser',
sourcemap: true,
},
resolve: {
Expand Down
Loading

0 comments on commit 3968a90

Please sign in to comment.