@vue-solana/nuxt 4.1.0 → 4.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +67 -2
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -12,7 +12,9 @@ Nuxt module for Solana wallet, RPC, account, token, message signing, live data,
12
12
  This package is part of the Vue Solana family. Choose based on your app framework:
13
13
 
14
14
  - [`@vue-solana/core`](https://www.npmjs.com/package/@vue-solana/core) — framework-agnostic Solana primitives: Kit RPC client helpers, wallet types, Android MWA registration, iOS browser wallet helpers, message signing, token account reads, and transaction helpers. **Use this directly** when you want shared RPC/wallet/transaction helpers without installing a Vue plugin (non-Vue apps, server/relayer code, or your own framework integration).
15
+
15
16
  - [`@vue-solana/vue`](https://www.npmjs.com/package/@vue-solana/vue) — Vue 3 plugin plus composables for RPC, account, balance, wallet, message signing, live data, and transactions. **Use this** in plain Vue 3 apps (Vite, etc.).
17
+
16
18
  - [`@vue-solana/nuxt`](https://www.npmjs.com/package/@vue-solana/nuxt) — Nuxt module that installs the Vue plugin and auto-imports the composables. **Use this** in Nuxt 3/4 apps. (This package.)
17
19
 
18
20
  This package builds on `@vue-solana/vue` and `@vue-solana/core`; it is the recommended entry point for Nuxt apps.
@@ -22,22 +24,35 @@ Use this package in Nuxt apps that need the Vue Solana plugin installed automati
22
24
  New to Solana? Start with the official docs and the project concepts guide:
23
25
 
24
26
  - [Solana Documentation](https://solana.com/docs)
27
+
25
28
  - [Solana RPC Methods](https://solana.com/docs/rpc)
29
+
26
30
  - [Solana Clusters](https://solana.com/docs/references/clusters)
31
+
27
32
  - [Vue Solana Concepts Guide](https://vue-solana-docs.vercel.app/concepts/solana-for-vue-developers)
33
+
28
34
  - [`@vue-solana/nuxt` docs](https://vue-solana-docs.vercel.app/packages/nuxt)
35
+
29
36
  - [Agent Skill](https://vue-solana-docs.vercel.app/agent-skill)
37
+
30
38
  - [Live demo](https://vue-solana-docs.vercel.app/demo)
31
39
 
32
40
  ## Features
33
41
 
34
42
  - Installs the Vue Solana plugin automatically.
35
- - Auto-imports Solana RPC, wallet, account, token, message signing, live data, and transaction composables.
43
+
44
+ - Auto-imports Solana RPC, wallet, account, token, message signing, Solana Pay and QR, live data, and transaction composables.
45
+
36
46
  - Builds the default client with the official Kit RPC planner and transaction-sending executor; payer secrets are never accepted through public runtime config.
47
+
37
48
  - Uses direct Vue package subpaths to avoid pulling unrelated runtime code into Nuxt bundles.
49
+
38
50
  - Client-only runtime plugin with SSR-safe inert composable state before hydration.
51
+
39
52
  - Unified wallet discovery for browser extensions, Android Mobile Wallet Adapter, and supported iOS browser wallets.
53
+
40
54
  - App-wide selected wallet account context installed by the runtime plugin.
55
+
41
56
  - Nuxt 3 and Nuxt 4 support.
42
57
 
43
58
  ## Compatibility
@@ -49,6 +64,8 @@ New to Solana? Start with the official docs and the project concepts guide:
49
64
  | Solana client | Provided through `@vue-solana/core` |
50
65
  | Clusters | `mainnet` (alias `mainnet-beta`), `devnet`, `testnet`, `localnet` |
51
66
 
67
+ <br>
68
+
52
69
  ## Install
53
70
 
54
71
  ```sh
@@ -102,6 +119,8 @@ Nuxt module options are stored in public runtime config, so they must be JSON-se
102
119
  | `iosWallet` | JSON-serializable iOS wallet options or `false` | Enabled on iOS browsers | Configures or disables iOS browser wallet universal links (Phantom, Solflare, Backpack). |
103
120
  | `clientPlugin` | `boolean` | `true` | Set to `false` to skip the module's runtime plugin and install `createSolanaPlugin` yourself. |
104
121
 
122
+ <br>
123
+
105
124
  For development, use `devnet` and request free test SOL from the official faucet:
106
125
 
107
126
  ```txt
@@ -113,42 +132,79 @@ https://faucet.solana.com
113
132
  The module auto-imports these composables from direct `@vue-solana/vue/*` subpaths rather than the root Vue package barrel. This keeps Nuxt SSR bundles from pulling in unrelated Solana runtime code just because a page uses one composable.
114
133
 
115
134
  - `useSolana()`
135
+
116
136
  - `useSolanaClient()`
137
+
117
138
  - `useSolanaRpc()`
139
+
118
140
  - `useSolanaConnection()`
141
+
119
142
  - `useSolanaAccountInfo()`
143
+
120
144
  - `useSolanaAirdrop()`
145
+
121
146
  - `useSolanaBalance()`
147
+
122
148
  - `useSolanaProgramAccounts()`
149
+
123
150
  - `useSolanaTokenAccounts()`
151
+
124
152
  - `useSolanaTokenBalance()`
153
+
125
154
  - `useSolanaWallet()`
155
+
126
156
  - `useSolanaWallets()`
157
+
127
158
  - `useSolanaSignMessage()`
159
+
128
160
  - `useSolanaSignIn()`
161
+
129
162
  - `useSolanaPay()`
163
+
130
164
  - `useSolanaPayConfirmation()`
165
+
131
166
  - `useSolanaQrCode()`
167
+
132
168
  - `useSolanaQrScanner()`
169
+
133
170
  - `useSolanaSignAndSendTransaction()`
171
+
134
172
  - `useSolanaSignTransactions()`
173
+
135
174
  - `useSolanaSignAndSendTransactions()`
175
+
136
176
  - `useSolanaTransactionConfirmation()`
177
+
137
178
  - `useSolanaSignatureStatus()`
179
+
138
180
  - `useSolanaTransaction()`
181
+
139
182
  - `useSolanaAction()`
183
+
140
184
  - `useSolanaRequest()`
185
+
141
186
  - `useSolanaSubscription()`
187
+
142
188
  - `useSolanaTrackedData()`
189
+
143
190
  - `useSolanaRequestSwr()`
191
+
144
192
  - `useSolanaSubscriptionSwr()`
193
+
145
194
  - `useSolanaTrackedDataSwr()`
195
+
146
196
  - `useSolanaSelectedWalletAccount()`
197
+
147
198
  - `useSolanaPayer()`
199
+
148
200
  - `useSolanaIdentity()`
201
+
149
202
  - `useSolanaPlanTransaction()`
203
+
150
204
  - `useSolanaPlanTransactions()`
205
+
151
206
  - `useSolanaSendTransaction()`
207
+
152
208
  - `useSolanaSendTransactions()`
153
209
 
154
210
  | Composable | Purpose |
@@ -167,7 +223,7 @@ The module auto-imports these composables from direct `@vue-solana/vue/*` subpat
167
223
  | `useSolanaWallets()` | Wallet discovery, selected wallet state, and selection actions. |
168
224
  | `useSolanaSignMessage()` | Wallet message signing. |
169
225
  | `useSolanaSignIn()` | Sign In With Solana (SIWS) trigger returning a server-verifiable result. |
170
- | `useSolanaPay()` | Builds/parses Solana Pay transfer request URLs and tracks confirmation status by reference. |
226
+ | `useSolanaPay()` | Builds/parses Solana Pay transfer request URLs, generates a reference, and verifies settlement against it. |
171
227
  | `useSolanaPayConfirmation()` | Polls payment status for a Solana Pay reference. |
172
228
  | `useSolanaQrCode()` | Renders a Solana Pay URL as an SVG QR code. |
173
229
  | `useSolanaQrScanner()` | Scans Solana Pay QR codes through the camera and `BarcodeDetector`. |
@@ -198,6 +254,8 @@ The module auto-imports these composables from direct `@vue-solana/vue/*` subpat
198
254
  | `useSolanaSendTransaction()` | Plans, signs, submits, and confirms one transaction through the client. |
199
255
  | `useSolanaSendTransactions()` | Sends a batch of transactions (parallel or sequential) through the client. |
200
256
 
257
+ <br>
258
+
201
259
  The default client built by the module composes `solanaRpc()` followed by `rpcAirdrop()` when no `commitment` is configured (a configured `commitment` builds the same stack explicitly so it reaches the RPC layer); `solanaRpc()` installs `rpcTransactionPlanner()`, `rpcTransactionPlanSigningExecutor()`, and `rpcTransactionPlanSendingExecutor()` itself. The old custom fallback sender is not used. `useSolanaSendTransaction()` and `useSolanaSendTransactions()` therefore use the official client-sending capability, but the module does not configure a payer because `payer` and `payerSecretKey` are omitted from `ModuleOptions`. Their `sent` status is reached after the official executor completes its send-and-confirm operation at `confirmed` commitment.
202
260
 
203
261
  The runtime plugin is client-only. Auto-imported composables can be called during SSR and return inert state until hydration provides the real client context. Trigger RPC and wallet work from client lifecycle hooks or user actions.
@@ -209,6 +267,7 @@ The module also installs the app-wide selected wallet account context, so `useSo
209
267
  The package also exposes Solana helper subpaths for Nuxt apps that need Kit re-exports or the browser Buffer polyfill without importing lower-level packages directly:
210
268
 
211
269
  - `@vue-solana/nuxt/kit`
270
+
212
271
  - `@vue-solana/nuxt/buffer-polyfill`
213
272
 
214
273
  ## Read RPC State
@@ -357,11 +416,17 @@ Docs: [Vue Solana Agent Skill](https://vue-solana-docs.vercel.app/agent-skill)
357
416
  ## Caveats
358
417
 
359
418
  - The runtime plugin is client-only. Auto-imported composables are SSR-safe, but real RPC and wallet work should run after hydration or in user actions.
419
+
360
420
  - The SWR cache (`useSolanaRequestSwr()`, `useSolanaSubscriptionSwr()`, `useSolanaTrackedDataSwr()`) is module-level and shared across SSR requests. Namespace cache keys per request or call `clearSwrCache()` (auto-imported) at the start of each server request to avoid leaking cached data between requests. The cache is capped at 1024 entries with oldest-first eviction; `deleteSwrKey()` (auto-imported) evicts a single key by its full cache key.
421
+
361
422
  - Nuxt module options are stored in public runtime config, so they must be JSON-serializable.
423
+
362
424
  - Public Solana RPC endpoints are useful for development, but production apps should use dedicated RPC infrastructure.
425
+
363
426
  - Broad `useSolanaProgramAccounts()` scans can be expensive or blocked on public RPC nodes. Prefer narrow filters and `dataSlice`.
427
+
364
428
  - Use `mainnet` for Solana mainnet. This is Solana's official mainnet cluster name; the legacy `mainnet-beta` spelling is still accepted and redirects to the same endpoint.
429
+
365
430
  - Desktop native app wallets are planned but not implemented yet.
366
431
 
367
432
  ## Status
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vue-solana/nuxt",
3
- "version": "4.1.0",
3
+ "version": "4.1.2",
4
4
  "description": "Nuxt module for Solana applications.",
5
5
  "license": "MIT",
6
6
  "keywords": [
@@ -45,7 +45,7 @@
45
45
  "access": "public"
46
46
  },
47
47
  "dependencies": {
48
- "@vue-solana/vue": "4.1.0"
48
+ "@vue-solana/vue": "4.1.2"
49
49
  },
50
50
  "peerDependencies": {
51
51
  "nuxt": "^3.0.0 || ^4.0.0"