Skip to content
This repository has been archived by the owner on May 16, 2024. It is now read-only.

Commit

Permalink
Merge pull request #119 from unicape/1.x
Browse files Browse the repository at this point in the history
chore: fix doc & script
  • Loading branch information
unicape authored Jan 5, 2024
2 parents 790599f + d211419 commit b3f2255
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 4 deletions.
14 changes: 12 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,14 +49,24 @@ export const config = createConfig({

In this example, Wagmi is configured to use the Mainnet and Sepolia chains, and **injected** connector. Check out the **createConfig** [docs](https://wagmi.sh/react/api/createConfig) for more configuration options.

## Use Wagmi Initialization
## Setup Use Wagmi

Before using Vue Query, you need to initialize it using `UseWagmiPlugin`

```ts
import { UseWagmiPlugin } from 'use-wagmi'

app.use(VueQueryPlugin, vueQueryOptions, { config })
app.use(UseWagmiPlugin, { config })
```

## Setup TanStack Query

Inside the `VueQueryPlugin`, wrap your app in a TanStack Query Vue Plugin, e.g. VueQueryPlugin, and pass a new QueryClient instance to the client property.

```ts
import { VueQueryPlugin } from "@tanstack/vue-query"

app.use(VueQueryPlugin)
```

## Use of Composition API with `<script setup>`
Expand Down
8 changes: 6 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,18 @@
"private": true,
"type": "module",
"scripts": {
"build": "pnpm run --r --filter \"./packages/vue\" build",
"build": "pnpm run --r --filter \"./packages/**\" build",
"changeset:publish": "pnpm version:update && pnpm build && bun .scripts/formatPackageJson.ts && bun .scripts/generateProxyPackages.ts && changeset publish",
"changeset:version": "changeset version && pnpm version:update",
"clean": "pnpm run --r --parallel clean",
"format": "biome format . --write",
"lint": "biome check .",
"lint:fix": "pnpm lint --apply",
"lint:unused": "pnpm clean && knip --ignore-internal",
"dev": "pnpm --filter vite-vue dev",
"typecheck": "pnpm run --r --parallel typecheck && tsc --noEmit"
"typecheck": "pnpm run --r --parallel typecheck && tsc --noEmit",
"version:update": "bun .scripts/updateVersion.ts",
"version:update:viem": "bun .scripts/updateViemVersion.ts"
},
"devDependencies": {
"@biomejs/biome": "1.1.2",
Expand Down

0 comments on commit b3f2255

Please sign in to comment.