Skip to content

Commit

Permalink
chore: revert devnet
Browse files Browse the repository at this point in the history
  • Loading branch information
crypblizz8 committed Nov 26, 2024
1 parent 822e756 commit 0d9eb8e
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ This will create a new Nillion app in the your desired directory.

1. Installs `nilup`, the Nillion SDK tool installer and version manager
2. Clones an example Next.js project with App Router Settings
a. Installs `@nillion/client-react-hooks` which has all your needs to use Nillion and Nada.
a. Installs `@nillion/client-react-hooks` \* `@nillion/client-vms` which has all your needs to use Nillion and Nada.
3. Installs an Nada projects with a pyenv
4. Then follow along the QuickStart [guide](https://docs.nillion.com/quickstart-install) to do the following:
- Create a simple Nada App
Expand Down
20 changes: 10 additions & 10 deletions examples/nextjs/app/components/LoginButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const LoginButton: FC<LoginButtonProps> = ({
const [isLoading, setIsLoading] = useState(false);
const [error, setError] = useState<string | null>(null);

const NETWORK: NetworkType = "testnet"; // devnet or testnet <-- Change here.
const NETWORK: NetworkType = "devnet"; // devnet or testnet <-- Change here.
const isTestnet = (network: NetworkType): network is "testnet" => network === "testnet";

const chainId = "nillion-chain-testnet-1";
Expand All @@ -29,18 +29,18 @@ export const LoginButton: FC<LoginButtonProps> = ({

try {
// For DEVNET
// const client = await createClient({
// network: NETWORK,
// });

// Uncomment the following line to use TESTNET + Keplr wallet
const client = await createClient({
network: NETWORK,
seed: "example-user-seed",
//@ts-expect-error window keplr types
keplr: window.keplr,
});

// Uncomment the following line to use TESTNET + Keplr wallet
// const client = await createClient({
// network: NETWORK,
// seed: "example-user-seed",
// //@ts-expect-error window keplr types
// keplr: window.keplr,
// });

onClientCreated(client);

if (isTestnet(NETWORK)) {
Expand Down Expand Up @@ -104,7 +104,7 @@ export const LoginButton: FC<LoginButtonProps> = ({
Connecting...
</span>
) : isConnected ? (
walletAddress && NETWORK === "testnet" ? (
walletAddress && isTestnet(NETWORK) ? (
`${walletAddress?.substring(0, 11)}...${walletAddress?.substring(walletAddress.length - 3)}`
) : (
"Logout"
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@nillion/create-nillion-app",
"version": "0.2.0-rc.1",
"version": "0.2.0-rc.3",
"main": "dist/src/index.js",
"types": "dist/src/index.d.ts",
"type": "module",
Expand Down

0 comments on commit 0d9eb8e

Please sign in to comment.