Skip to content

Commit

Permalink
refactor: update wagmi adapter to pass custom wagmi params to createC…
Browse files Browse the repository at this point in the history
…onfig function (#2985)
  • Loading branch information
enesozturk authored Oct 3, 2024
1 parent c2e391d commit b949143
Show file tree
Hide file tree
Showing 38 changed files with 23,292 additions and 105 deletions.
39 changes: 39 additions & 0 deletions .changeset/loud-shirts-flash.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
---
'@examples/next-wagmi-ssr': patch
'@reown/appkit-adapter-wagmi': patch
'@apps/demo': patch
'@apps/gallery': patch
'@apps/laboratory': patch
'@examples/html-ethers': patch
'@examples/html-ethers5': patch
'@examples/html-wagmi': patch
'@examples/next-ethers': patch
'@examples/next-wagmi': patch
'@examples/react-ethers': patch
'@examples/react-ethers5': patch
'@examples/react-solana': patch
'@examples/react-wagmi': patch
'@examples/vue-ethers5': patch
'@examples/vue-solana': patch
'@examples/vue-wagmi': patch
'@reown/appkit-adapter-ethers': patch
'@reown/appkit-adapter-ethers5': patch
'@reown/appkit-adapter-polkadot': patch
'@reown/appkit-adapter-solana': patch
'@reown/appkit': patch
'@reown/appkit-utils': patch
'@reown/appkit-cdn': patch
'@reown/appkit-common': patch
'@reown/appkit-core': patch
'@reown/appkit-ethers': patch
'@reown/appkit-ethers5': patch
'@reown/appkit-polyfills': patch
'@reown/appkit-scaffold-ui': patch
'@reown/appkit-siwe': patch
'@reown/appkit-solana': patch
'@reown/appkit-ui': patch
'@reown/appkit-wagmi': patch
'@reown/appkit-wallet': patch
---

Updates wagmi adapter to pass all custom wagmi configs to the createConfig function
1 change: 1 addition & 0 deletions examples/next-wagmi-app-router/.env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
NEXT_PUBLIC_PROJECT_ID=
3 changes: 3 additions & 0 deletions examples/next-wagmi-app-router/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"extends": "next/core-web-vitals"
}
37 changes: 37 additions & 0 deletions examples/next-wagmi-app-router/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js
.yarn/install-state.gz

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# local env files
.env*.local
.env

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts
36 changes: 36 additions & 0 deletions examples/next-wagmi-app-router/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
This is a [Next.js](https://nextjs.org) project bootstrapped with [`create-next-app`](https://nextjs.org/docs/app/api-reference/cli/create-next-app).

## Getting Started

First, run the development server:

```bash
npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev
```

Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.

You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file.

This project uses [`next/font`](https://nextjs.org/docs/app/building-your-application/optimizing/fonts) to automatically optimize and load [Geist](https://vercel.com/font), a new font family for Vercel.

## Learn More

To learn more about Next.js, take a look at the following resources:

- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.

You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js) - your feedback and contributions are welcome!

## Deploy on Vercel

The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.

Check out our [Next.js deployment documentation](https://nextjs.org/docs/app/building-your-application/deploying) for more details.
9 changes: 9 additions & 0 deletions examples/next-wagmi-app-router/next.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
/** @type {import('next').NextConfig} */
const nextConfig = {
webpack: config => {
config.externals.push('pino-pretty', 'lokijs', 'encoding')
return config
}
}

export default nextConfig
31 changes: 31 additions & 0 deletions examples/next-wagmi-app-router/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{
"name": "@examples/next-wagmi-app-router",
"version": "1.0.5",
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start",
"lint": "next lint"
},
"dependencies": {
"@tanstack/react-query": "5.56.2",
"@reown/appkit": "workspace:*",
"@reown/appkit-adapter-wagmi": "workspace:*",
"@wagmi/core": "2.13.4",
"next": "14.2.3",
"react": "18.2.0",
"react-dom": "18.2.0",
"viem": "2.21.4",
"wagmi": "2.12.9"
},
"devDependencies": {
"@types/react": "18.2.62",
"@types/react-dom": "18.2.7",
"@types/node": "20.11.5",
"eslint": "8.56.0",
"eslint-config-next": "14.1.0",
"typescript": "5.3.3",
"esbuild": "0.21.1"
}
}
Loading

0 comments on commit b949143

Please sign in to comment.