Skip to content

Commit 5c4c45e

Browse files
committed
docs(apps): add Builder Code attribution to migration quickstart config
1 parent 7c9b5fa commit 5c4c45e

1 file changed

Lines changed: 10 additions & 3 deletions

File tree

docs/apps/quickstart/migrate-to-standard-web-app.mdx

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,15 +44,21 @@ Your app uses the Farcaster SDK. The migration replaces Farcaster-specific auth,
4444
Install wagmi, viem, and React Query if you don't have them already:
4545

4646
```bash Terminal
47-
npm install wagmi viem @tanstack/react-query @base-org/account
47+
npm install wagmi viem ox @tanstack/react-query @base-org/account
4848
```
4949

5050
Create a wagmi config for Base and wrap your app with `WagmiProvider` and `QueryClientProvider`:
5151

52-
```tsx config.ts lines expandable wrap
52+
```tsx config.ts lines expandable wrap highlight={4,6-9,24}
5353
import { http, createConfig, createStorage, cookieStorage } from 'wagmi';
5454
import { base } from 'wagmi/chains';
5555
import { baseAccount, injected } from 'wagmi/connectors';
56+
import { Attribution } from 'ox/erc8021';
57+
58+
// Get your Builder Code from base.dev > Settings > Builder Code
59+
const DATA_SUFFIX = Attribution.toDataSuffix({
60+
codes: ['YOUR-BUILDER-CODE'],
61+
});
5662

5763
export const config = createConfig({
5864
chains: [base],
@@ -67,6 +73,7 @@ Your app uses the Farcaster SDK. The migration replaces Farcaster-specific auth,
6773
transports: {
6874
[base.id]: http(),
6975
},
76+
dataSuffix: DATA_SUFFIX,
7077
});
7178

7279
declare module 'wagmi' {
@@ -173,7 +180,7 @@ Your app uses the Farcaster SDK. The migration replaces Farcaster-specific auth,
173180
</Step>
174181

175182
<Step title="Register on Base.dev">
176-
If you haven't registered yet, create a project at [Base.dev](https://www.base.dev) and complete your app metadata: name, icon, tagline, description, screenshots, category, primary URL, and [builder code](/apps/builder-codes/builder-codes). Already registered apps do not need to re-register or update metadata.
183+
If you haven't registered yet, create a project at [Base.dev](https://www.base.dev) and complete your app metadata: name, icon, tagline, description, screenshots, category, primary URL, and [builder code](/apps/builder-codes/builder-codes). Already registered apps do not need to re-register or update metadata. To attribute transactions from web users outside the Base App browser, also add your Builder Code as a `dataSuffix` to your wagmi config. See [Builder Codes for App Developers](/apps/builder-codes/app-developers).
177184
</Step>
178185
</Steps>
179186

0 commit comments

Comments
 (0)