Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(docs) : Add Network Overview Page #3491

Merged
merged 39 commits into from
Nov 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
7913e45
Add network overview page
vivekjain23 Oct 21, 2024
c2be3e6
Add network table component
vivekjain23 Oct 21, 2024
12700c0
Add network overview page to sidebar
vivekjain23 Oct 21, 2024
d2c153b
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Oct 21, 2024
4469e69
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Oct 21, 2024
38637a7
Fix sidebar
vivekjain23 Oct 22, 2024
5eceafc
Fix and move interface to constants
vivekjain23 Oct 22, 2024
3b8bae1
Fix import path
vivekjain23 Oct 22, 2024
726c1e2
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Oct 22, 2024
4c9e16d
Fix Network Info component
vivekjain23 Oct 22, 2024
addd32f
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Oct 28, 2024
4104088
Add localnet endpoints to network overview page and fixes
vivekjain23 Oct 28, 2024
c72ee09
Update overview page and fixes
vivekjain23 Oct 29, 2024
576a73a
Update tooltip
vivekjain23 Oct 29, 2024
0cc87e5
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Oct 29, 2024
e2490b3
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Oct 29, 2024
3f60f0b
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Oct 29, 2024
4ad2938
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Oct 29, 2024
515ed15
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Oct 29, 2024
1bc10d5
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Oct 30, 2024
026a058
Move network overview page
vivekjain23 Nov 4, 2024
2972553
Create a link to and from network overview doc
vivekjain23 Nov 4, 2024
0c908a8
Add description to developer
vivekjain23 Nov 6, 2024
bca3c47
Add testnet and devnet table and fixes
vivekjain23 Nov 6, 2024
9930623
Update tooltip
vivekjain23 Nov 6, 2024
aa1666e
Fix network table component and update doc
vivekjain23 Nov 6, 2024
7c76c9f
Fix typo
vivekjain23 Nov 6, 2024
377d3af
Fix faucet URL
vivekjain23 Nov 6, 2024
1319ec7
Fix document layout
vivekjain23 Nov 7, 2024
5af7122
Add testnet and devnet constants
vivekjain23 Nov 7, 2024
2397db2
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Nov 7, 2024
64ce818
Fix constants
vivekjain23 Nov 8, 2024
166d8be
Use constants in network overview page
vivekjain23 Nov 8, 2024
208baec
Cleanup network info component
vivekjain23 Nov 8, 2024
836faf3
Fix mainnet info
vivekjain23 Nov 8, 2024
82de3d0
Fix mainnet constant value
vivekjain23 Nov 8, 2024
3a1c9e3
Merge branch 'develop' into devx/feat-network-overview-page
vivekjain23 Nov 8, 2024
54a16d0
Update constants name
vivekjain23 Nov 8, 2024
d5d7578
Update docs/content/sidebars/developer.js
vivekjain23 Nov 8, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions docs/content/developer/developer.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ If you are completely new to Move, you should start with the aptly named Getting

Go to [Getting Started](getting-started/getting-started.mdx).

## Network Overview

The [Network Overview](network-overview.mdx) page gives an overview of the different networks available in the IOTA ecosystem.

## IOTA 101

The IOTA 101 section introduces the basics of IOTA that help you create smart contracts. These topics assume you are familiar with Move and the IOTA blockchain.
Expand Down
4 changes: 4 additions & 0 deletions docs/content/developer/getting-started/connect.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ import questions from '/json/developer/getting-started/connect.json';

# Connect to an IOTA Network

:::info
The [Network Overview](/developer/network-overview) section lists all the networks available in the IOTA ecosystem.
:::

## IOTA CLI

IOTA provides the [IOTA command line interface (CLI)](/references/cli/client.mdx) to interact with [IOTA networks](#iota-networks), it does the following and more:
Expand Down
4 changes: 4 additions & 0 deletions docs/content/developer/getting-started/local-network.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,10 @@ The response resembles the following, but with different IDs:
╰────────────────────────────────────────────────────────────────────┴────────────╯
```

:::tip explorer
In order to use the explorer locally users can use the deployed explorer and set another endpoint like this: [https://explorer.iota.cafe/?network=http%3A%2F%2F127.0.0.1%3A9000](https://explorer.iota.cafe/?network=http%3A%2F%2F127.0.0.1%3A9000) or manually provide a Custom RPC URL on the [Explorer](https://explorer.iota.cafe/) page in the top right corner.
:::

## Install IOTA Wallet Locally

### Prerequisites
Expand Down
38 changes: 38 additions & 0 deletions docs/content/developer/network-overview.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
description: This page gives an overview around the different networks available in the IOTA ecosystem.

tags: [getting-started, devnet, testnet, mainnet]
---

# Network Overview

This pages gives an overview around the different networks available in the IOTA ecosystem.

import NetworkInfo from "@site/src/components/NetworkInfo/index.tsx";
import { Networks } from '@site/src/components/constant.tsx';

:::info
In general, all endpoints are load-balanced but also subject to rate limiting. If you are developing a production-level application for IOTA, consider [setting up your own infrastructure](/developer/getting-started/local-network) to have more control and avoid any limits.
:::

## IOTA Mainnet

:::note
The Mainnet and Devnet have not yet gone live.
:::

<NetworkInfo.Move {...Networks['iota_move']}/>

## IOTA Testnet

<NetworkInfo.Move {...Networks['iota_move_testnet']}/>

## IOTA Devnet

<NetworkInfo.Move {...Networks['iota_move_devnet']}/>

## IOTA Localnet

To create a local IOTA network, you can refer to [Local Development](/developer/getting-started/local-network) page.

<NetworkInfo.Move {...Networks['iota_localnet']}/>
1 change: 1 addition & 0 deletions docs/content/sidebars/developer.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ const developer = [
'developer/getting-started/coffee-example',
],
},
'developer/network-overview',
{
type: 'category',
label: 'IOTA 101',
Expand Down
157 changes: 155 additions & 2 deletions docs/site/src/components/NetworkInfo/index.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
import React from 'react';
import React, { useState } from 'react';
import { ChainId } from '../ChainId';
import { NetworkProps } from '../constant';
import { NetworkProps, MoveProps } from '../constant';
import CodeBlock from '@theme/CodeBlock';
import Admonition from '@theme/Admonition';

// L1 component
function L1(props: NetworkProps) {
return (
<table>
Expand Down Expand Up @@ -49,6 +50,98 @@ function L1(props: NetworkProps) {
);
}

// Testnet Component
function Testnet(props: NetworkProps) {
return (
<table>
<tbody>
<tr>
<th>Base Token</th>
<td>{props.baseToken}</td>
</tr>
{props.protocol &&<tr>
<th>Protocol</th>
<td>{props.protocol}</td>
</tr>}
<tr>
<th>HTTP REST API</th>
<td>
<CodeBlock>{props.httpRestApi}</CodeBlock>
</td>
</tr>
<tr>
<th>Event API</th>
<td>
<CodeBlock>{props.eventApi}</CodeBlock>
</td>
</tr>
<tr>
<th>Permanode API</th>
<td>
<CodeBlock>{props.permaNodeApi}</CodeBlock>
</td>
</tr>
{props.faucet && (
<tr>
<th>Faucet</th>
<td>
<a href={props.faucet} target='_blank' rel='noopener noreferrer'>
{props.faucet}
</a>
</td>
</tr>
)}
</tbody>
</table>
);
}

// Devtnet Component
function Devnet(props: NetworkProps) {
return (
<table>
<tbody>
<tr>
<th>Base Token</th>
<td>{props.baseToken}</td>
</tr>
<tr>
<th>Protocol</th>
<td>{props.protocol}</td>
</tr>
<tr>
<th>HTTP REST API</th>
<td>
<CodeBlock>{props.httpRestApi}</CodeBlock>
</td>
</tr>
<tr>
<th>Event API</th>
<td>
<CodeBlock>{props.eventApi}</CodeBlock>
</td>
</tr>
<tr>
<th>Permanode API</th>
<td>
<CodeBlock>{props.permaNodeApi}</CodeBlock>
</td>
</tr>
{props.faucet && (
<tr>
<th>Faucet</th>
<td>
<a href={props.faucet} target='_blank' rel='noopener noreferrer'>
{props.faucet}
</a>
</td>
</tr>
)}
</tbody>
</table>
);
}
// EVM component
function Evm(props: NetworkProps) {
return (
<table>
Expand Down Expand Up @@ -134,6 +227,7 @@ function Evm(props: NetworkProps) {
);
}

// EvmCustom component
function EvmCustom(props: NetworkProps) {
return (
<table>
Expand All @@ -159,8 +253,67 @@ function EvmCustom(props: NetworkProps) {
);
}

// Move component
function Move(props: MoveProps) {
return (
<table>
<tbody>
<tr>
<th>Base Token</th>
<td>{props.baseToken}</td>
</tr>
{props.explorerUrl && (
<tr>
<th scope="row">Explorer URL</th>
<td>
<CodeBlock>{props.explorerUrl}</CodeBlock>
</td>
</tr>
)}
<tr>
<th>JSON RPC URL</th>
<td>
<CodeBlock>{props.jsonRpcUrl}</CodeBlock>
</td>
</tr>
<tr>
<th>Indexer RPC</th>
<td>
<CodeBlock>{props.indexerRpc}</CodeBlock>
</td>
</tr>
<tr>
<th>GraphQL RPC</th>
<td>
<CodeBlock>{props.graphqlRpc}</CodeBlock>
</td>
</tr>
<tr>
<th>RPC Websocket URL</th>
<td>
<CodeBlock>{props.jsonRpcWebsocketUrl}</CodeBlock>
</td>
</tr>
{props.faucet && (
<tr>
<th>Faucet URL</th>
<td>
<a href={props.faucetUrl} target="_blank" rel="noopener noreferrer">
{props.faucetUrl}
</a>
</td>
</tr>
)}
</tbody>
</table>
);
}

export default {
L1,
Evm,
EvmCustom,
Move,
Testnet,
Devnet
};
62 changes: 53 additions & 9 deletions docs/site/src/components/constant.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,6 @@ export const Networks = {
api: 'https://api.evm.iotaledger.net',
},
},
iota_2_testnet: {
baseToken: 'Testnet Token (no value)',
protocol: 'IOTA 2.0',
httpRestApi: 'https://api.nova-testnet.iotaledger.net/',
eventApi: 'wss://api.nova-testnet.iotaledger.net:443 (MQTT 3.1, /mqtt)',
permaNodeApi: 'https://chronicle.nova-testnet.iotaledger.net',
explorer: 'https://explorer.iota.org/iota2-testnet',
faucet: 'https://faucet.nova-testnet.iotaledger.net',
},
iota_testnet: {
baseToken: 'Testnet Token (no value)',
protocol: 'Stardust',
Expand Down Expand Up @@ -91,6 +82,15 @@ export const Networks = {
api: 'https://api.evm.testnet.iotaledger.net',
},
},
iota_2_testnet: {
baseToken: 'Testnet Token (no value)',
protocol: 'IOTA 2.0',
httpRestApi: 'https://api.nova-testnet.iotaledger.net/',
eventApi: 'wss://api.nova-testnet.iotaledger.net:443 (MQTT 3.1, /mqtt)',
permaNodeApi: 'https://chronicle.nova-testnet.iotaledger.net',
explorer: 'https://explorer.iota.org/iota2-testnet',
faucet: 'https://faucet.nova-testnet.iotaledger.net',
},
shimmer: {
baseToken: 'Shimmer Token',
protocol: 'Stardust',
Expand Down Expand Up @@ -155,6 +155,41 @@ export const Networks = {
api: 'https://api.evm.testnet.shimmer.network',
},
},
iota_move: {
baseToken: 'IOTA Token',
jsonRpcUrl: 'jsonRpcUrl placeholder',
jsonRpcWebsocketUrl:'jsonRpcWebsocketUrl placeholder',
indexerRpc: 'indexerRpc placeholder',
graphqlRpc: 'graphqlRpc placeholder',
faucetUrl: 'faucetUrl placeholder',
explorerUrl: 'explorerUrl placeholder'
},
iota_move_testnet: {
baseToken: 'IOTA Token (no value)',
jsonRpcUrl: 'https://api.iota-rebased-alphanet.iota.cafe',
jsonRpcWebsocketUrl:'wss://api.iota-rebased-alphanet.iota.cafe',
indexerRpc: 'https://indexer.iota-rebased-alphanet.iota.cafe',
graphqlRpc: 'https://graphql.iota-rebased-alphanet.iota.cafe',
faucetUrl: 'https://api.iota-rebased-alphanet.iota.cafe/gas',
explorerUrl: 'https://explorer.iota.cafe/?network=alphanet'
},
iota_move_devnet: {
baseToken: 'IOTA Token (no value)',
jsonRpcUrl: 'jsonRpcUrl placeholder',
jsonRpcWebsocketUrl:'jsonRpcWebsocketUrl placeholder',
indexerRpc: 'indexerRpc placeholder',
graphqlRpc: 'graphqlRpc placeholder',
faucetUrl: 'faucetUrl placeholder',
explorerUrl: 'explorerUrl placeholder'
},
iota_localnet: {
baseToken:"IOTA Token",
jsonRpcUrl: 'http://127.0.0.1:9000',
jsonRpcWebsocketUrl:'ws://127.0.0.1:9000',
indexerRpc: 'http://127.0.0.1:9124',
graphqlRpc: 'http://127.0.0.1:8000',
faucetUrl: 'http://127.0.0.1:9123/gas'
},
};

export interface Toolkit {
Expand Down Expand Up @@ -192,3 +227,12 @@ export interface NetworkProps {
api?: string;
};
}

export interface MoveProps {
jsonRpcUrl: string;
jsonRpcWebsocketUrl: string;
indexerRpc: string;
graphqlRpc: string;
faucetUrl: string;
explorerUrl?: string;
};
Loading