Skip to content

Commit

Permalink
fix mainnet to alchemy
Browse files Browse the repository at this point in the history
  • Loading branch information
starknetdev committed Jan 15, 2024
1 parent e7549ea commit a79e2a3
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions ui/src/app/provider.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
"use client";
import React from "react";
import { Connector, StarknetConfig, blastProvider } from "@starknet-react/core";
import {
Connector,
StarknetConfig,
alchemyProvider,
blastProvider,
} from "@starknet-react/core";
import { goerli, mainnet } from "@starknet-react/chains";

export function StarknetProvider({
Expand All @@ -13,7 +18,7 @@ export function StarknetProvider({
const apiKey = process.env.NEXT_PUBLIC_RPC_API_KEY!;
const onMainnet = process.env.NEXT_PUBLIC_NETWORK === "mainnet";
const provider = onMainnet
? blastProvider({ apiKey })
? alchemyProvider({ apiKey })
: blastProvider({ apiKey });
const chains = onMainnet ? [mainnet] : [goerli];
return (
Expand Down

0 comments on commit a79e2a3

Please sign in to comment.