├── .dockerignore ├── .eslintrc.js ├── .github ├── CODEOWNERS ├── actions │ └── base-setup │ │ └── action.yaml ├── dependabot.yaml └── workflows │ └── cicd.yaml ├── .gitignore ├── .npmrc ├── .nvmrc ├── .prettierrc ├── .vscode └── settings.json ├── Dockerfile ├── README.md ├── amplify.yml ├── ask-cookbook.d.ts ├── cspell.json ├── cspell └── project-words.txt ├── eslint.config.js ├── global-env.d.ts ├── next-env.d.ts ├── next-sitemap.config.js ├── next.config.mjs ├── package.json ├── pnpm-lock.yaml ├── postcss.config.js ├── public ├── downloads │ ├── ink-brand-kit.zip │ ├── ink-logos.zip │ └── ink-typeface.zip ├── images │ ├── banner.webp │ ├── brand-kit │ │ ├── docs-color.png │ │ ├── docs-hero.png │ │ ├── docs-logo-extension-kraken.png │ │ ├── docs-logo-partnerships.png │ │ ├── docs-logo-stacked.png │ │ ├── docs-logo-symbol-margin.png │ │ ├── docs-logo-symbol.png │ │ ├── docs-logo-wordmark-margin.png │ │ ├── docs-logo-wordmark.png │ │ └── docs-type.png │ └── ink-banner.mp4 ├── img │ └── icons │ │ └── favicon.ico └── logo │ ├── build-the-future.png │ ├── icon.svg │ ├── ink-logo-dark.svg │ ├── ink-logo-light.svg │ └── logo.svg ├── src ├── components │ ├── AddNetworkButton.tsx │ ├── AskCookbook.tsx │ ├── BlockExplorersContentWrapper.tsx │ ├── BridgesContentWrapper.tsx │ ├── Button.tsx │ ├── ClientOnlyAskCookbook.tsx │ ├── CommunityContentWrapper.tsx │ ├── CopyButton.tsx │ ├── CopyableCode.tsx │ ├── CrosschainContentWrapper.tsx │ ├── DownloadButton.tsx │ ├── FaucetsContentWrapper.tsx │ ├── Footer.tsx │ ├── Head.tsx │ ├── MultisigContentWrapper.tsx │ ├── SidebarTitleComponent.tsx │ ├── TestnetDisclaimer.tsx │ ├── ThemeToggle.tsx │ └── Toc.tsx ├── content │ └── shared │ │ ├── _badges.mdx │ │ ├── block-explorers-content.mdx │ │ ├── bridges-content.mdx │ │ ├── community-content.mdx │ │ ├── crosschain-content.mdx │ │ ├── faucets-content.mdx │ │ └── multisig-content.mdx ├── fonts.ts ├── globals.css ├── icons │ ├── Check.tsx │ ├── ConnectedPulse.tsx │ ├── Download.tsx │ ├── InkLogo.tsx │ ├── Moon.tsx │ ├── Pencil.tsx │ ├── Sun.tsx │ └── ThumbUp.tsx ├── images │ ├── add_network.png │ ├── blockscout_verif_1_ink.png │ ├── blockscout_verif_2_ink.png │ ├── blockscout_verif_3_ink.png │ ├── gas_fees.png │ ├── ink-banner.png │ ├── remix_deploy_1.png │ ├── remix_deploy_2.png │ ├── remix_deploy_3.png │ ├── remix_deploy_4.png │ ├── remix_deploy_5.png │ └── vrf.png ├── pages │ ├── 404.mdx │ ├── 500.mdx │ ├── _app.mdx │ ├── _meta.json │ ├── build │ │ ├── _meta.json │ │ ├── getting-started.mdx │ │ ├── ink-kit.mdx │ │ ├── onchain-clients.mdx │ │ ├── transaction-fees.mdx │ │ ├── tutorials.mdx │ │ ├── tutorials │ │ │ ├── _meta.json │ │ │ ├── deploying-a-smart-contract │ │ │ │ ├── _meta.json │ │ │ │ ├── foundry.mdx │ │ │ │ ├── hardhat.mdx │ │ │ │ └── remix.mdx │ │ │ ├── deploying-a-superchainerc20.mdx │ │ │ ├── shipping-on-the-superchain.mdx │ │ │ └── verify-smart-contract.mdx │ │ └── verify.mdx │ ├── faq.mdx │ ├── general │ │ ├── _meta.json │ │ ├── about.mdx │ │ ├── connect-wallet.mdx │ │ ├── faucet.mdx │ │ ├── network-information.mdx │ │ ├── support.mdx │ │ └── support │ │ │ ├── _meta.json │ │ │ └── troubleshooting.mdx │ ├── index.mdx │ ├── status.mdx │ ├── tools │ │ ├── _meta.json │ │ ├── account-abstraction.mdx │ │ ├── block-explorers.mdx │ │ ├── bridges.mdx │ │ ├── crosschain.mdx │ │ ├── faucets.mdx │ │ ├── indexers.mdx │ │ ├── multisig.mdx │ │ ├── oracles.mdx │ │ ├── rpc.mdx │ │ ├── security.mdx │ │ └── vrf.mdx │ ├── useful-information │ │ ├── _meta.json │ │ ├── contracts.mdx │ │ ├── ink-contracts.mdx │ │ ├── ink-token-contracts.mdx │ │ └── the-superchain.mdx │ └── work-with-ink │ │ ├── _meta.json │ │ ├── brand-kit.mdx │ │ ├── community.mdx │ │ └── contributing.mdx ├── types │ └── mdx.d.ts └── utils │ ├── networks.ts │ └── urls.ts ├── tailwind.config.js ├── theme.config.tsx └── tsconfig.json /.dockerignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | .github 3 | .next 4 | dist 5 | .env* 6 | *.log 7 | .git 8 | .gitignore 9 | -------------------------------------------------------------------------------- /.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | extends: ["next/core-web-vitals", "prettier"], 3 | plugins: ["simple-import-sort"], 4 | rules: { 5 | "react-hooks/exhaustive-deps": "error", 6 | "import/newline-after-import": [ 7 | "error", 8 | { 9 | count: 1, 10 | }, 11 | ], 12 | // increase the severity of rules so they are auto-fixable 13 | "simple-import-sort/imports": [ 14 | "error", 15 | { 16 | groups: [ 17 | // Packages `react` related packages come first. 18 | ["^react", "^@?\\w"], 19 | // Internal packages. 20 | ["^(@)(/.*|$)"], 21 | // Side effect imports. 22 | ["^\\u0000"], 23 | // Parent imports. Put `..` last. 24 | ["^\\.\\.(?!/?$)", "^\\.\\./?$"], 25 | // Other relative imports. Put same-folder imports and `.` last. 26 | ["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"], 27 | // Style imports. 28 | ["^.+\\.?(css)$"], 29 | ], 30 | }, 31 | ], 32 | "simple-import-sort/exports": "error", 33 | }, 34 | }; 35 | -------------------------------------------------------------------------------- /.github/CODEOWNERS: -------------------------------------------------------------------------------- 1 | * @inkonchain/developers-secret -------------------------------------------------------------------------------- /.github/actions/base-setup/action.yaml: -------------------------------------------------------------------------------- 1 | name: 'Basic Setup' 2 | description: 'Basic setup with pnpm and cache restore' 3 | runs: 4 | using: "composite" 5 | steps: 6 | - name: Setup pnpm 7 | uses: pnpm/action-setup@v2 8 | with: 9 | run_install: false 10 | 11 | - name: Setup Node 22 12 | uses: actions/setup-node@v4 13 | with: 14 | node-version: "22.x" 15 | cache: "pnpm" 16 | 17 | - name: Add pnpm store path to env var 18 | id: pnpm-cache 19 | shell: bash 20 | run: echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT 21 | 22 | - name: Restore Cache 23 | uses: actions/cache@v4 24 | with: 25 | path: | 26 | ${{ steps.pnpm-cache.outputs.STORE_PATH }} 27 | **/node_modules 28 | key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} 29 | restore-keys: | 30 | ${{ runner.os }}-pnpm-store- 31 | 32 | -------------------------------------------------------------------------------- /.github/dependabot.yaml: -------------------------------------------------------------------------------- 1 | version: 2 2 | updates: 3 | - package-ecosystem: "npm" 4 | directory: "/" 5 | schedule: 6 | interval: "weekly" -------------------------------------------------------------------------------- /.github/workflows/cicd.yaml: -------------------------------------------------------------------------------- 1 | name: CI/CD Workflow 2 | on: 3 | pull_request: 4 | push: 5 | branches: 6 | - main 7 | 8 | jobs: 9 | install_modules: 10 | runs-on: ubuntu-latest 11 | steps: 12 | - uses: actions/checkout@v4 13 | - uses: volta-cli/action@v4 14 | - uses: pnpm/action-setup@v4 15 | with: 16 | run_install: false 17 | - uses: actions/setup-node@v4 18 | with: 19 | node-version: "22.x" 20 | cache: "pnpm" 21 | - name: Install dependencies 22 | run: pnpm install --frozen-lockfile 23 | - name: Add pnpm store path to env var 24 | id: pnpm-cache 25 | shell: bash 26 | run: echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT 27 | - name: Cache node modules 28 | uses: actions/cache@v4 29 | with: 30 | path: | 31 | ${{ steps.pnpm-cache.outputs.STORE_PATH }} 32 | **/node_modules 33 | key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} 34 | restore-keys: | 35 | ${{ runner.os }}-pnpm-store- 36 | 37 | js-lint: 38 | needs: install_modules 39 | runs-on: ubuntu-latest 40 | steps: 41 | - uses: actions/checkout@v4 42 | - uses: ./.github/actions/base-setup 43 | name: Base Setup 44 | - name: JS linting 45 | run: pnpm run lint:js 46 | 47 | md-lint: 48 | needs: install_modules 49 | runs-on: ubuntu-latest 50 | steps: 51 | - uses: actions/checkout@v4 52 | - uses: ./.github/actions/base-setup 53 | name: Base Setup 54 | - name: MDX linting 55 | run: pnpm run lint:mdx 56 | 57 | format: 58 | needs: install_modules 59 | runs-on: ubuntu-latest 60 | steps: 61 | - uses: actions/checkout@v4 62 | - uses: ./.github/actions/base-setup 63 | name: Base Setup 64 | - name: Run formatting 65 | run: pnpm run format:js 66 | 67 | # spell-check: 68 | # needs: install_modules 69 | # runs-on: ubuntu-latest 70 | # steps: 71 | # - uses: actions/checkout@v4 72 | # - uses: ./.github/actions/base-setup 73 | # name: Base Setup 74 | # - name: Run Spellcheck 75 | # run: pnpm run spellcheck:lint 76 | 77 | build: 78 | needs: install_modules 79 | runs-on: ubuntu-latest 80 | steps: 81 | - uses: actions/checkout@v4 82 | - uses: ./.github/actions/base-setup 83 | name: Base Setup 84 | - name: Building app 85 | run: pnpm run build 86 | - name: Cache build 87 | uses: actions/cache/save@v4 88 | with: 89 | path: .next 90 | key: ${{ runner.os }}-build-store-${{ hashFiles('.next') }} 91 | 92 | docker-publish: 93 | if: github.ref == 'refs/heads/main' 94 | runs-on: ubuntu-latest 95 | needs: build 96 | steps: 97 | - name: Checkout code 98 | uses: actions/checkout@v4 99 | 100 | - name: Set up Docker Buildx 101 | uses: docker/setup-buildx-action@v2 102 | 103 | - name: Log in to GitHub Container Registry 104 | uses: docker/login-action@v2 105 | with: 106 | registry: ghcr.io 107 | username: ${{ github.actor }} 108 | password: ${{ secrets.GITHUB_TOKEN }} 109 | 110 | - name: Build and push Docker image 111 | uses: docker/build-push-action@v5 112 | with: 113 | context: . 114 | push: true 115 | tags: ghcr.io/inkonchain/docs:latest 116 | 117 | - name: Log out from GitHub Container Registry 118 | run: docker logout ghcr.io 119 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # packages 2 | node_modules 3 | 4 | # os specific files 5 | .DS_Store 6 | 7 | # build artifacts 8 | .next 9 | public/robots.txt 10 | public/sitemap-0.xml 11 | public/sitemap.xml 12 | 13 | # log files 14 | *.log 15 | 16 | out 17 | -------------------------------------------------------------------------------- /.npmrc: -------------------------------------------------------------------------------- 1 | # https://www.npmjs.com/package/next-sitemap#building-sitemaps-with-pnpm 2 | enable-pre-post-scripts=true 3 | -------------------------------------------------------------------------------- /.nvmrc: -------------------------------------------------------------------------------- 1 | v22.14.0 2 | -------------------------------------------------------------------------------- /.prettierrc: -------------------------------------------------------------------------------- 1 | { 2 | "trailingComma": "es5", 3 | "tabWidth": 2, 4 | "semi": true, 5 | "singleQuote": false 6 | } -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "editor.formatOnSave": true, 3 | "editor.defaultFormatter": "esbenp.prettier-vscode", 4 | "[typescriptreact, javascript]": { 5 | "editor.defaultFormatter": "esbenp.prettier-vscode", 6 | "editor.codeActionsOnSave": { 7 | "source.fixAll.eslint": "explicit" 8 | } 9 | }, 10 | "[plaintext]": { 11 | "editor.formatOnSave": false 12 | }, 13 | "editor.formatOnPaste": false, 14 | "prettier.useEditorConfig": false, 15 | "prettier.useTabs": false, 16 | "prettier.configPath": ".prettierrc", 17 | "prettier.prettierPath": "node_modules/prettier" 18 | } 19 | -------------------------------------------------------------------------------- /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM node:22-alpine 2 | RUN corepack enable && corepack prepare pnpm@9.12.3 --activate 3 | WORKDIR /app 4 | COPY package.json pnpm-lock.yaml ./ 5 | RUN pnpm install --frozen-lockfile 6 | COPY . . 7 | RUN pnpm run build 8 | RUN adduser --system --uid 1001 docs-user 9 | USER docs-user 10 | EXPOSE 3000 11 | CMD ["pnpm", "start"] 12 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | [![Twitter](https://img.shields.io/twitter/follow/inkonchain)](https://x.com/inkonchain) 2 | 3 | # InkChain Documentation App 4 | 5 | An advanced, streamlined documentation platform built with Next.js and Nextra for InkChain. 6 | 7 | ## 🚀 Build & Run 8 | 9 | 1. **Build Docker image**: 10 | ```bash 11 | docker build -t docs . 12 | ``` 13 | 14 | 2. **Run Docker container**: 15 | ```bash 16 | docker run -p 3000:3000 docs 17 | ``` 18 | 19 | ## 📋 Requirements 20 | 21 | * **Node.js**: v20.11.0 or higher 22 | 23 | ## 📖 Overview 24 | 25 | This is a documentation application powered by [Nextra](https://nextra.site/) and built on [Next.js](https://nextjs.org/). Nextra simplifies the creation of documentation sites, allowing us to leverage the **Pages Router** for efficient navigation and routing. Currently, due to compatibility limitations, we have not yet upgraded to the App Router. 26 | 27 | ## 🏁 Getting Started 28 | 29 | To get started with local development: 30 | 31 | 1. **Clone the repository** 32 | 2. **Install dependencies**: 33 | ```bash 34 | pnpm install 35 | ``` 36 | 3. **Start development server**: 37 | ```bash 38 | pnpm run dev 39 | ``` 40 | 41 | ## 🛠 Tooling 42 | 43 | Our development setup includes multiple tools to maintain high-quality code and documentation: 44 | 45 | * **[CSpell](https://cspell.org/)**: Real-time spell checking to maintain documentation accuracy. 46 | * **[Remark](https://remark.js.org/)**: Processes and renders Markdown content with added plugins. 47 | * **[ESLint](https://eslint.org/)**: Ensures code quality by catching potential issues. 48 | * **[Prettier](https://prettier.io/)**: Enforces consistent code formatting. 49 | * **[Tailwind CSS](https://tailwindcss.com/)**: Utility-first CSS framework for fast, responsive UI development. 50 | 51 | ## 🚦 CI/CD Pipeline 52 | 53 | Our CI/CD setup utilizes GitHub Actions to run automated checks on every pull request (PR): 54 | 55 | * **js-lint**: Ensures proper JavaScript code formatting with ESLint. 56 | * **md-lint**: Checks Markdown code formatting with Remark. 57 | * **format**: Enforces consistent code style with Prettier. 58 | * **spell-check**: Uses CSpell to verify correct spelling in the documentation. For any unique terms (e.g., "InkChain"), add them to the [`./cspell/project-words.txt`](./cspell/project-words.txt) file to whitelist. 59 | 60 | ## 🌐 Feature Branch Deployment 61 | 62 | For every new PR, our CI/CD pipeline deploys a temporary environment via **AWS Amplify**. This real-time deployment enables live testing and review of changes before merging, ensuring a smoother workflow. The deployment URL is automatically provided within the PR checks, allowing team members to interact with new features. 63 | 64 | ## 🚀 Production Deployment 65 | 66 | The `main` branch is configured for automatic continuous deployment via **AWS Amplify**. Every merge triggers a new build and deployment, ensuring that the latest version of the documentation is available to users without manual intervention. 67 | -------------------------------------------------------------------------------- /amplify.yml: -------------------------------------------------------------------------------- 1 | version: 1 2 | frontend: 3 | phases: 4 | preBuild: 5 | commands: 6 | - npm install -g pnpm 7 | - pnpm install --frozen-lockfile 8 | build: 9 | commands: 10 | - pnpm run build 11 | artifacts: 12 | baseDirectory: .next 13 | files: 14 | - '**/*' 15 | cache: 16 | paths: 17 | - node_modules/**/* 18 | -------------------------------------------------------------------------------- /ask-cookbook.d.ts: -------------------------------------------------------------------------------- 1 | // Solves the following error: "Cannot find module ... or its corresponding type declarations. There are types at ..., but this result could not be resolved under your current 'moduleResolution' setting. Consider updating to 'node16', 'nodenext', or 'bundler'. [2307]" 2 | declare module "@cookbookdev/docsbot/react" { 3 | export { default } from "@cookbookdev/docsbot/dist/react/index.d.ts"; 4 | } 5 | -------------------------------------------------------------------------------- /cspell.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://raw.githubusercontent.com/streetsidesoftware/cspell/main/cspell.schema.json", 3 | "version": "0.2", 4 | "dictionaryDefinitions": [ 5 | { 6 | "name": "project-words", 7 | "path": "./cspell/project-words.txt", 8 | "addWords": true 9 | } 10 | ], 11 | "dictionaries": [ 12 | "project-words" 13 | ], 14 | "ignorePaths": [ 15 | "node_modules", 16 | "/project-words.txt" 17 | ] 18 | } -------------------------------------------------------------------------------- /cspell/project-words.txt: -------------------------------------------------------------------------------- 1 | Blockscout 2 | inkchain 3 | Superchain’s 4 | blockscout 5 | amet 6 | adipiscing 7 | elit 8 | eiusmod 9 | tempor 10 | incididunt 11 | labore 12 | dolore 13 | aliqua 14 | enim 15 | veniam 16 | quis 17 | nostrud 18 | ullamco 19 | laboris 20 | aliquip 21 | commodo 22 | consequat 23 | Duis 24 | aute 25 | irure 26 | reprehenderit 27 | voluptate 28 | velit 29 | cillum 30 | fugiat 31 | nulla 32 | pariatur 33 | Excepteur 34 | occaecat 35 | cupidatat 36 | proident 37 | sunt 38 | officia 39 | deserunt 40 | mollit 41 | laborum 42 | CSpell: Files checked: 11, Issues found: 42 in 4 files. 43 | adipiscing 44 | aliqua 45 | aliquip 46 | amet 47 | aute 48 | Blockscout 49 | blockscout 50 | cillum 51 | commodo 52 | consequat 53 | cupidatat 54 | deserunt 55 | dolore 56 | Duis 57 | eiusmod 58 | elit 59 | enim 60 | Excepteur 61 | fugiat 62 | incididunt 63 | irure 64 | labore 65 | laboris 66 | laborum 67 | mollit 68 | nostrud 69 | nulla 70 | occaecat 71 | officia 72 | pariatur 73 | proident 74 | quis 75 | reprehenderit 76 | sunt 77 | tempor 78 | ullamco 79 | velit 80 | veniam 81 | voluptate 82 | untar 83 | NVME 84 | nextra 85 | Gelato 86 | QuickNode 87 | Superchain 88 | Sepolia 89 | userbase 90 | synergizing 91 | vewy 92 | scawy 93 | Brid 94 | Rabby 95 | Protofire 96 | Zerodev 97 | Permissionless 98 | Crosschain 99 | Supersim 100 | verif 101 | Sourcify 102 | sourcify 103 | sourcecode 104 | Superbridge 105 | inkonchain 106 | Drand 107 | Viem 108 | viem 109 | hackathons 110 | Goldsky 111 | Multicall 112 | Mintable 113 | Permissioned 114 | preinstalls 115 | multisignatures 116 | baselayer 117 | Smol 118 | foundryup 119 | inksepolia 120 | INKSEPOLIA 121 | commoditizes 122 | multichain 123 | Routescan 124 | Lurus 125 | wordmark 126 | SEDA 127 | -------------------------------------------------------------------------------- /eslint.config.js: -------------------------------------------------------------------------------- 1 | const simpleImportSort = require("eslint-plugin-simple-import-sort"); 2 | const path = require("node:path"); 3 | const js = require("@eslint/js"); 4 | const { FlatCompat } = require("@eslint/eslintrc"); 5 | 6 | const baseDirectory = __dirname; 7 | const compat = new FlatCompat({ 8 | baseDirectory: baseDirectory, 9 | recommendedConfig: js.configs.recommended, 10 | allConfig: js.configs.all, 11 | }); 12 | 13 | module.exports = [ 14 | // Default ignores - node_modules is ignored by default in recent ESLint, but good to be explicit. 15 | // Add other ignores if needed (e.g., build output directories like .next) 16 | { 17 | ignores: ["**/node_modules/**", "**/.next/**", "**/out/**"], 18 | }, 19 | 20 | // Spread the configurations from extended configs 21 | ...compat.extends("next/core-web-vitals", "prettier"), 22 | 23 | // Configuration for JS/JSX/TS/TSX files 24 | { 25 | files: ["**/*.js", "**/*.jsx", "**/*.ts", "**/*.tsx"], 26 | plugins: { 27 | // Use the imported object directly as the key 28 | simpleImportSort: simpleImportSort, 29 | }, 30 | rules: { 31 | "react-hooks/exhaustive-deps": "error", 32 | "import/newline-after-import": ["error", { count: 1 }], 33 | "simpleImportSort/imports": [ 34 | "error", 35 | { 36 | groups: [ 37 | ["^react", "^@?\\w"], 38 | ["^(@)(/.*|$)"], 39 | ["^\\u0000"], 40 | ["^\\.\\.(?!/?$)", "^\\.\\./?$"], 41 | ["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"], 42 | ["^.+\\.?(css)$"], 43 | ], 44 | }, 45 | ], 46 | "simpleImportSort/exports": "error", 47 | }, 48 | }, 49 | ]; 50 | -------------------------------------------------------------------------------- /global-env.d.ts: -------------------------------------------------------------------------------- 1 | interface Window { 2 | ethereum: any; 3 | } 4 | -------------------------------------------------------------------------------- /next-env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | /// 3 | 4 | // NOTE: This file should not be edited 5 | // see https://nextjs.org/docs/pages/api-reference/config/typescript for more information. 6 | -------------------------------------------------------------------------------- /next-sitemap.config.js: -------------------------------------------------------------------------------- 1 | /** @type {import('next-sitemap').IConfig} */ 2 | module.exports = { 3 | exclude: ['*/_meta'], 4 | siteUrl: 'https://docs.inkonchain.com', 5 | generateRobotsTxt: true, 6 | robotsTxtOptions: { 7 | policies: [ 8 | { 9 | userAgent: '*', 10 | allow: '/', 11 | }, 12 | ] 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /next.config.mjs: -------------------------------------------------------------------------------- 1 | import nextra from "nextra"; 2 | import path from "path"; 3 | import remarkCodeImport from "remark-code-import"; 4 | import { fileURLToPath } from "url"; 5 | 6 | const __dirname = path.dirname(fileURLToPath(import.meta.url)); 7 | 8 | const withNextra = nextra({ 9 | theme: "nextra-theme-docs", 10 | themeConfig: "./theme.config.tsx", 11 | defaultShowCopyCode: true, 12 | mdxOptions: { 13 | remarkPlugins: [remarkCodeImport], 14 | }, 15 | }); 16 | 17 | const config = withNextra({ 18 | eslint: { 19 | ignoreDuringBuilds: true, 20 | }, 21 | images: { 22 | unoptimized: true, 23 | }, 24 | webpack: (config) => { 25 | config.resolve.alias = { 26 | ...config.resolve.alias, 27 | "@": path.join(__dirname, "src"), 28 | }; 29 | return config; 30 | }, 31 | experimental: { 32 | mdxRs: true, 33 | }, 34 | }); 35 | 36 | export default config; 37 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "inkchain-docs", 3 | "volta": { 4 | "node": "22.14.0", 5 | "pnpm": "9.12.3" 6 | }, 7 | "packageManager": "pnpm@9.12.3", 8 | "scripts": { 9 | "dev": "next dev", 10 | "build": "next build", 11 | "postbuild": "next-sitemap", 12 | "start": "next start", 13 | "lint": "pnpm run lint:js && pnpm run lint:mdx && pnpm run format:js:check && pnpm run spellcheck:lint", 14 | "lint:fix": "pnpm run lint:js:fix && pnpm run lint:mdx:fix && pnpm run format:js && pnpm run spellcheck:fix", 15 | "lint:js": "eslint ./src theme.config.tsx --ext js,jsx,ts,tsx", 16 | "lint:js:fix": "eslint ./src theme.config.tsx --fix --ext js,jsx,ts,tsx", 17 | "format:js": "prettier --write \"**/*.{ts,tsx,css,scss}\"", 18 | "format:js:check": "prettier --check \"**/*.{ts,tsx,css,scss}\"", 19 | "lint:mdx": "remark . --quiet --frail", 20 | "lint:mdx:fix": "remark . -o --quiet", 21 | "spellcheck:lint": "cspell lint \"**/*.mdx\"", 22 | "spellcheck:fix": "cspell --words-only --unique \"**/*.mdx\" | sort --ignore-case | uniq" 23 | }, 24 | "remarkConfig": { 25 | "settings": { 26 | "emphasis": "*", 27 | "strong": "*" 28 | }, 29 | "plugins": [ 30 | "remark-frontmatter", 31 | "remark-preset-lint-consistent", 32 | "remark-preset-lint-recommended", 33 | "remark-gfm", 34 | [ 35 | "remark-mdx", 36 | { 37 | "commonmark": true, 38 | "extensions": [ 39 | ".mdx" 40 | ], 41 | "jsx": true 42 | } 43 | ], 44 | "remark-lint-frontmatter-schema", 45 | "remark-lint-heading-style", 46 | "remark-lint-list-item-indent", 47 | "remark-lint-table-cell-padding", 48 | "remark-lint-table-pipe-alignment", 49 | "remark-lint-table-pipes", 50 | "remark-lint-unordered-list-marker-style" 51 | ] 52 | }, 53 | "dependencies": { 54 | "@cookbookdev/docsbot": "4.25.10", 55 | "clsx": "2.1.1", 56 | "next": "15.3.2", 57 | "next-sitemap": "4.2.3", 58 | "next-themes": "0.4.6", 59 | "nextra": "2.13.4", 60 | "nextra-theme-docs": "2.13.4", 61 | "react": "18.3.1", 62 | "react-dom": "18.3.1" 63 | }, 64 | "devDependencies": { 65 | "@eslint/eslintrc": "3.3.1", 66 | "@eslint/js": "9.27.0", 67 | "@types/node": "22.15.24", 68 | "@types/react": "18.3.12", 69 | "@types/react-dom": "18.3.1", 70 | "autoprefixer": "10.4.21", 71 | "cspell": "9.0.2", 72 | "eslint": "9.27.0", 73 | "eslint-config-next": "15.3.2", 74 | "eslint-config-prettier": "10.1.5", 75 | "eslint-plugin-import": "2.31.0", 76 | "eslint-plugin-mdx": "3.4.2", 77 | "eslint-plugin-simple-import-sort": "12.1.1", 78 | "mdx": "0.3.1", 79 | "postcss": "8.5.3", 80 | "prettier": "3.5.3", 81 | "remark": "15.0.1", 82 | "remark-cli": "12.0.1", 83 | "remark-code-import": "1.2.0", 84 | "remark-frontmatter": "5.0.0", 85 | "remark-gfm": "4.0.1", 86 | "remark-lint-frontmatter-schema": "3.15.4", 87 | "remark-lint-heading-style": "4.0.1", 88 | "remark-lint-list-item-indent": "4.0.1", 89 | "remark-lint-table-cell-padding": "5.1.1", 90 | "remark-lint-table-pipe-alignment": "4.1.1", 91 | "remark-lint-table-pipes": "5.0.1", 92 | "remark-lint-unordered-list-marker-style": "4.0.1", 93 | "remark-mdx": "3.1.0", 94 | "remark-preset-lint-consistent": "6.0.1", 95 | "remark-preset-lint-recommended": "7.0.1", 96 | "tailwindcss": "3.4.17", 97 | "typescript": "5.8.3" 98 | } 99 | } 100 | -------------------------------------------------------------------------------- /postcss.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: { 3 | tailwindcss: {}, 4 | autoprefixer: {}, 5 | }, 6 | } 7 | -------------------------------------------------------------------------------- /public/downloads/ink-brand-kit.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/downloads/ink-brand-kit.zip -------------------------------------------------------------------------------- /public/downloads/ink-logos.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/downloads/ink-logos.zip -------------------------------------------------------------------------------- /public/downloads/ink-typeface.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/downloads/ink-typeface.zip -------------------------------------------------------------------------------- /public/images/banner.webp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/banner.webp -------------------------------------------------------------------------------- /public/images/brand-kit/docs-color.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/brand-kit/docs-color.png -------------------------------------------------------------------------------- /public/images/brand-kit/docs-hero.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/brand-kit/docs-hero.png -------------------------------------------------------------------------------- /public/images/brand-kit/docs-logo-extension-kraken.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/brand-kit/docs-logo-extension-kraken.png -------------------------------------------------------------------------------- /public/images/brand-kit/docs-logo-partnerships.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/brand-kit/docs-logo-partnerships.png -------------------------------------------------------------------------------- /public/images/brand-kit/docs-logo-stacked.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/brand-kit/docs-logo-stacked.png -------------------------------------------------------------------------------- /public/images/brand-kit/docs-logo-symbol-margin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/brand-kit/docs-logo-symbol-margin.png -------------------------------------------------------------------------------- /public/images/brand-kit/docs-logo-symbol.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/brand-kit/docs-logo-symbol.png -------------------------------------------------------------------------------- /public/images/brand-kit/docs-logo-wordmark-margin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/brand-kit/docs-logo-wordmark-margin.png -------------------------------------------------------------------------------- /public/images/brand-kit/docs-logo-wordmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/brand-kit/docs-logo-wordmark.png -------------------------------------------------------------------------------- /public/images/brand-kit/docs-type.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/brand-kit/docs-type.png -------------------------------------------------------------------------------- /public/images/ink-banner.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/images/ink-banner.mp4 -------------------------------------------------------------------------------- /public/img/icons/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/img/icons/favicon.ico -------------------------------------------------------------------------------- /public/logo/build-the-future.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/public/logo/build-the-future.png -------------------------------------------------------------------------------- /public/logo/icon.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /public/logo/ink-logo-dark.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /public/logo/ink-logo-light.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /public/logo/logo.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/components/AddNetworkButton.tsx: -------------------------------------------------------------------------------- 1 | import { CheckIcon } from "@/icons/Check"; 2 | import { ConnectedPulse } from "@/icons/ConnectedPulse"; 3 | import { 4 | networkParams, 5 | NetworkType, 6 | useNetwork, 7 | UseNetworkResponse, 8 | } from "@/utils/networks"; 9 | 10 | import { Button } from "./Button"; 11 | 12 | interface AddNetworkButtonProps { 13 | network: NetworkType; 14 | heading: string; 15 | } 16 | 17 | export const AddNetworkButton = ({ 18 | network, 19 | heading, 20 | }: AddNetworkButtonProps) => { 21 | const { isWalletInstalled, isAdded, isSelected, addNetwork, selectNetwork } = 22 | useNetwork(network); 23 | 24 | return ( 25 |
26 |
27 |

28 | {heading} 29 | {isSelected && } 30 | 36 |

37 | 45 |
46 |
47 | ); 48 | }; 49 | const AddNetworkButtonContent = ({ 50 | isWalletInstalled, 51 | isAdded, 52 | isSelected, 53 | addNetwork, 54 | selectNetwork, 55 | network, 56 | }: UseNetworkResponse & { network: NetworkType }) => { 57 | if (!isWalletInstalled) { 58 | return

No wallet connected

; 59 | } 60 | 61 | if (isAdded && isSelected) { 62 | return ( 63 | 64 | Network added & selected. 65 | 66 | ); 67 | } 68 | 69 | if (isAdded) { 70 | return ( 71 | 72 |

Network added.

73 |

77 | Click here to select it. 78 |

79 |
80 | ); 81 | } 82 | 83 | return ( 84 | 87 | ); 88 | }; 89 | -------------------------------------------------------------------------------- /src/components/AskCookbook.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | import BaseAskCookbook from "@cookbookdev/docsbot/react"; 3 | 4 | /** It's going to be exposed in HTTP requests anyway so it's fine to just hardcode it here */ 5 | const COOKBOOK_PUBLIC_API_KEY = 6 | "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiI2NzNlNTU5ZjBjOWIwZGRjZTE5OTAwMTIiLCJpYXQiOjE3MzIxMzgzOTksImV4cCI6MjA0NzcxNDM5OX0.L7-tnJwEIoDwxtju0yr5T4Xb9ahjIae8ob4dVbzoADM"; 7 | export const AskCookbook = () => { 8 | return ; 9 | }; 10 | -------------------------------------------------------------------------------- /src/components/BlockExplorersContentWrapper.tsx: -------------------------------------------------------------------------------- 1 | import CopyableCode from "@/components/CopyableCode"; 2 | import BlockExplorersContent from "@/content/shared/block-explorers-content.mdx"; 3 | 4 | export function BlockExplorersContentWrapper() { 5 | const components = { 6 | CopyableCode, 7 | }; 8 | 9 | return ; 10 | } 11 | -------------------------------------------------------------------------------- /src/components/BridgesContentWrapper.tsx: -------------------------------------------------------------------------------- 1 | import CopyableCode from "@/components/CopyableCode"; 2 | import BridgesContent from "@/content/shared/bridges-content.mdx"; 3 | 4 | export function BridgesContentWrapper() { 5 | const components = { 6 | CopyableCode, 7 | }; 8 | 9 | return ; 10 | } 11 | -------------------------------------------------------------------------------- /src/components/Button.tsx: -------------------------------------------------------------------------------- 1 | import { PropsWithChildren } from "react"; 2 | import clsx from "clsx"; 3 | 4 | interface ButtonProps { 5 | variant: "primary" | "secondary"; 6 | onClick?: () => void; 7 | className?: string; 8 | } 9 | 10 | export const Button: React.FC> = ({ 11 | children, 12 | variant, 13 | onClick, 14 | className, 15 | }) => { 16 | return ( 17 | 32 | ); 33 | }; 34 | -------------------------------------------------------------------------------- /src/components/ClientOnlyAskCookbook.tsx: -------------------------------------------------------------------------------- 1 | import React from "react"; 2 | import dynamic from "next/dynamic"; 3 | 4 | // Dynamically import the original AskCookbook component with SSR disabled 5 | const AskCookbookDynamic = dynamic( 6 | () => import("./AskCookbook").then((mod) => mod.AskCookbook), 7 | { 8 | ssr: false, 9 | } 10 | ); 11 | 12 | // This wrapper component simply renders the dynamically imported one 13 | const ClientOnlyAskCookbook: React.FC = () => { 14 | return ; 15 | }; 16 | 17 | export default ClientOnlyAskCookbook; 18 | -------------------------------------------------------------------------------- /src/components/CommunityContentWrapper.tsx: -------------------------------------------------------------------------------- 1 | import CopyableCode from "@/components/CopyableCode"; 2 | import CommunityContent from "@/content/shared/community-content.mdx"; 3 | 4 | export function CommunityContentWrapper() { 5 | const components = { 6 | CopyableCode, 7 | }; 8 | 9 | return ; 10 | } 11 | -------------------------------------------------------------------------------- /src/components/CopyButton.tsx: -------------------------------------------------------------------------------- 1 | "use client"; 2 | 3 | import { useState } from "react"; 4 | 5 | interface CopyButtonProps { 6 | text: string; 7 | className?: string; 8 | } 9 | 10 | export default function CopyButton({ text, className = "" }: CopyButtonProps) { 11 | const [copied, setCopied] = useState(false); 12 | 13 | const handleCopy = async () => { 14 | try { 15 | await navigator.clipboard.writeText(text); 16 | setCopied(true); 17 | setTimeout(() => setCopied(false), 2000); 18 | } catch (err) { 19 | console.error("Failed to copy:", err); 20 | } 21 | }; 22 | 23 | return ( 24 | 52 | ); 53 | } 54 | -------------------------------------------------------------------------------- /src/components/CopyableCode.tsx: -------------------------------------------------------------------------------- 1 | "use client"; 2 | 3 | import CopyButton from "./CopyButton"; 4 | 5 | interface CopyableCodeProps { 6 | code: string; 7 | display?: string; 8 | className?: string; 9 | href?: string; 10 | } 11 | 12 | export default function CopyableCode({ 13 | code, 14 | display, 15 | className = "", 16 | href, 17 | }: CopyableCodeProps) { 18 | const CodeContent = () => ( 19 | 20 | {display || code} 21 | 22 | ); 23 | 24 | return ( 25 | 26 | {href ? ( 27 | 33 | 34 | 35 | ) : ( 36 | 37 | )} 38 | 39 | 40 | ); 41 | } 42 | -------------------------------------------------------------------------------- /src/components/CrosschainContentWrapper.tsx: -------------------------------------------------------------------------------- 1 | import CopyableCode from "@/components/CopyableCode"; 2 | import CrosschainContent from "@/content/shared/crosschain-content.mdx"; 3 | 4 | export function CrosschainContentWrapper() { 5 | const components = { 6 | CopyableCode, 7 | }; 8 | 9 | return ; 10 | } 11 | -------------------------------------------------------------------------------- /src/components/DownloadButton.tsx: -------------------------------------------------------------------------------- 1 | import { PropsWithChildren } from "react"; 2 | 3 | import { DownloadIcon } from "@/icons/Download"; 4 | 5 | import { Button } from "./Button"; 6 | 7 | interface DownloadButtonProps { 8 | sourceFilePath: string; 9 | destinationFileName: string; 10 | label: string; 11 | size: string; 12 | } 13 | 14 | export const DownloadButton: React.FC< 15 | PropsWithChildren 16 | > = ({ sourceFilePath, destinationFileName, label, size }) => { 17 | return ( 18 | 35 | ); 36 | }; 37 | -------------------------------------------------------------------------------- /src/components/FaucetsContentWrapper.tsx: -------------------------------------------------------------------------------- 1 | import CopyableCode from "@/components/CopyableCode"; 2 | import FaucetsContent from "@/content/shared/faucets-content.mdx"; 3 | 4 | export function FaucetsContentWrapper() { 5 | const components = { 6 | CopyableCode, 7 | }; 8 | 9 | return ; 10 | } 11 | -------------------------------------------------------------------------------- /src/components/Footer.tsx: -------------------------------------------------------------------------------- 1 | import { ThemeToggle } from "./ThemeToggle"; 2 | 3 | export const Footer = () => { 4 | return ( 5 |
6 |
7 |
8 | Made with 💜 by the Ink team 9 |
10 | 15 | 20 | 21 |
22 |
23 | ); 24 | }; 25 | -------------------------------------------------------------------------------- /src/components/Head.tsx: -------------------------------------------------------------------------------- 1 | import { useRouter } from "next/router"; 2 | import { useConfig } from "nextra-theme-docs"; 3 | 4 | export const Head = () => { 5 | const { asPath, defaultLocale, locale } = useRouter(); 6 | const { frontMatter } = useConfig(); 7 | const baseUrl = "https://docs.inkonchain.com"; 8 | const url = 9 | baseUrl + (defaultLocale === locale ? asPath : `/${locale}${asPath}`); 10 | const title = 11 | frontMatter.title || "Ink Docs - The Official Developer Guide for Ink"; 12 | const description = 13 | frontMatter.description || 14 | "Comprehensive documentation for Ink, a cutting-edge Layer 2 (L2) blockchain built on Optimism's Superchain. Learn how to build, integrate, and leverage Ink's DeFi capabilities."; 15 | const ogImage = frontMatter.image || `${baseUrl}/logo/build-the-future.png`; 16 | 17 | return ( 18 | <> 19 | {/* Basic Meta Tags */} 20 | 21 | 22 | 23 | {/* Open Graph / Facebook */} 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | {/* Twitter */} 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | {/* Favicon */} 43 | 44 | 45 | ); 46 | }; 47 | -------------------------------------------------------------------------------- /src/components/MultisigContentWrapper.tsx: -------------------------------------------------------------------------------- 1 | import CopyableCode from "@/components/CopyableCode"; 2 | import MultisigContent from "@/content/shared/multisig-content.mdx"; 3 | 4 | export function MultisigContentWrapper() { 5 | const components = { 6 | CopyableCode, 7 | }; 8 | 9 | return ; 10 | } 11 | -------------------------------------------------------------------------------- /src/components/SidebarTitleComponent.tsx: -------------------------------------------------------------------------------- 1 | import clsx from "clsx"; 2 | import { useRouter } from "next/router"; 3 | 4 | interface SidebarTitleComponentProps { 5 | title: string; 6 | type: string; 7 | route: string; 8 | } 9 | 10 | export const SidebarTitleComponent: React.FC = ({ 11 | title, 12 | type, 13 | route, 14 | }) => { 15 | const { asPath } = useRouter(); 16 | const isActive = route === asPath; 17 | 18 | if (type === "separator") { 19 | return ( 20 |
{title}
21 | ); 22 | } 23 | 24 | return ( 25 |
36 | {title} 37 |
38 | ); 39 | }; 40 | -------------------------------------------------------------------------------- /src/components/TestnetDisclaimer.tsx: -------------------------------------------------------------------------------- 1 | import { Callout } from "nextra/components"; 2 | 3 | export const TestnetDisclaimer = () => { 4 | return ( 5 | 6 | This guide currently references Ink Sepolia (testnet) however, it can be 7 | used for Ink mainnet as well. Please be sure to change the necessary 8 | parameters based on your network of choice. 9 | 10 | ); 11 | }; 12 | -------------------------------------------------------------------------------- /src/components/ThemeToggle.tsx: -------------------------------------------------------------------------------- 1 | import { useEffect, useState } from "react"; 2 | import { useTheme } from "nextra-theme-docs"; 3 | 4 | import { MoonIcon } from "../icons/Moon"; 5 | import { SunIcon } from "../icons/Sun"; 6 | 7 | export const ThemeToggle = () => { 8 | const { resolvedTheme, setTheme } = useTheme(); 9 | const [isMounted, setIsMounted] = useState(false); 10 | 11 | const onToggleTheme = () => { 12 | if (resolvedTheme == "dark") { 13 | setTheme("light"); 14 | } else { 15 | setTheme("dark"); 16 | } 17 | }; 18 | 19 | /** 20 | * This is not ideal, but it's the best solution we have to avoid rendering the button 21 | * with the wrong color 22 | */ 23 | useEffect(() => { 24 | setIsMounted(true); 25 | }, [setIsMounted]); 26 | 27 | if (!isMounted) { 28 | return null; 29 | } 30 | 31 | return ( 32 | 39 | ); 40 | }; 41 | -------------------------------------------------------------------------------- /src/components/Toc.tsx: -------------------------------------------------------------------------------- 1 | import Link from "next/link"; 2 | 3 | import { PencilIcon } from "@/icons/Pencil"; 4 | import { ThumbUpIcon } from "@/icons/ThumbUp"; 5 | import { URLS } from "@/utils/urls"; 6 | 7 | interface Heading { 8 | id: string; 9 | depth: number; 10 | value: string; 11 | } 12 | 13 | interface TocProps { 14 | headings: Heading[]; 15 | } 16 | 17 | export const Toc: React.FC = ({ headings }) => { 18 | return ( 19 |
20 | {headings.length > 0 && ( 21 |
22 |
23 | On this page 24 |
25 | 26 |
    27 | {headings.map(({ id, value }) => ( 28 |
  • 29 | 30 | {value} 31 | 32 |
  • 33 | ))} 34 |
35 |
36 | )} 37 |
38 | 42 | 43 | Edit this page on GitHub 44 | 45 |
46 |
47 | ); 48 | }; 49 | -------------------------------------------------------------------------------- /src/content/shared/_badges.mdx: -------------------------------------------------------------------------------- 1 | # Badges 2 | 3 | ## Welcome To Ink 4 | 5 | > Awarded for bridging Ethereum to Ink. 6 | 7 | To bridge Ethereum, you can use the `L1StandardBridge` on the sepolia network crafted for Ink. 8 | 9 | There are two ways to do it: 10 | 11 | ### Gelato Bridge app 12 | 13 | The app provides a very simple UI to deposit or withdraw SepoliaETH from and to Sepolia Ink. 14 | 15 | Here is the app: [https://testnet-bridge.gelato.network/bridge/ink-sepolia](https://testnet-bridge.gelato.network/bridge/ink-sepolia) 16 | 17 | Connect your wallet, select the amount to transfer, and that's it! 18 | 19 | ### Directly calling the contract 20 | 21 | You can call the `bridgeETH` method in the contract here: [https://sepolia.etherscan.io/address/0xC0d337f71aD19a8f17a1b297cDb3a86c5EEf9Eec#writeProxyContract](https://sepolia.etherscan.io/address/0xC0d337f71aD19a8f17a1b297cDb3a86c5EEf9Eec#writeProxyContract) 22 | 23 | For instance, if you want to bridge 1 Sepolia ETH into 1 Sepolia "Ink" ETH: 24 | 25 | 1. Connect your Wallet using the "Connect to Wallet" button 26 | 2. Expand the `bridgeETH` method and enter `bridgeETH: 1` 27 | 3. Enter `_minGasLimit: 1000` (or whatever suits you) 28 | 4. Enter `_extraData: 0x00` 29 | 5. Click "Write", then validate the transaction in MetaMask, then sign it to complete the transaction. 30 | 31 | ## Wrapped ETH 32 | 33 | > Awarded for wrapping Ethereum into WETH. 34 | 35 | To create Wrapped ETH tokens (WETH), you can interact with the `deposit` method in the contract here: [https://explorer-sepolia.inkonchain.com/token/0x47d1f931eaff721549cc0ad57da81729baa8b4b2?tab=write\_contract](https://explorer-sepolia.inkonchain.com/token/0x47d1f931eaff721549cc0ad57da81729baa8b4b2?tab=write_contract) 36 | 37 | 1. Connect your Wallet using the button 38 | 2. Expand the `deposit` method and enter `Send native ETH: 10 000 000 000 000 000`. 39 | 40 | * This is equivalent to 0.01 ETH, adjust as needed 41 | 42 | 3. Click "Write", then validate the transaction in MetaMask, then sign it to complete the transaction. 43 | 44 | If you want the token to appear in MetaMask, click on the MetaMask button at the top of the page 45 | 46 | ## ERC20 Interactions 47 | 48 | > Awarded for minting, sending, and receiving ERC20 tokens. 49 | 50 | *coming soon* 51 | 52 | ## NFT Interactions 53 | 54 | > Awarded for minting, sending, and receiving NFTs. 55 | 56 | *coming soon* 57 | 58 | ## Faucet User 59 | 60 | > Awarded for using the Ink faucet. 61 | 62 | Get here: [https://mystery-faucet.demo.inkonchain.com/](https://mystery-faucet.demo.inkonchain.com/) 63 | 64 | Enter your address, enter the captcha, that's it! 65 | 66 | ## Smart Contract Deployer 67 | 68 | > Awarded for deploying a smart contract. 69 | 70 | *coming soon* 71 | -------------------------------------------------------------------------------- /src/content/shared/block-explorers-content.mdx: -------------------------------------------------------------------------------- 1 | ## Blockscout 2 | 3 | Blockscout is a universal block explorer providing detailed chain information and tools for debugging smart contracts and transactions. Visit the [Blockscout Docs](https://docs.blockscout.com/) for details. 4 | 5 | ###### Supported Networks 6 | 7 | * Ink Sepolia: [https://explorer-sepolia.inkonchain.com/](https://explorer-sepolia.inkonchain.com/) 8 | * API: [https://explorer-sepolia.inkonchain.com/api](https://explorer-sepolia.inkonchain.com/api) 9 | 10 | ###### Verifying Smart Contract Code on Blockscout 11 | 12 | * Please see [this tutorial](/build/tutorials/verify-smart-contract) 13 | 14 | ## Routescan 15 | 16 | Routescan is a unified explorer for over 54 blockchains. 17 | 18 | ###### Supported Networks 19 | 20 | * Ink Sepolia: [https://sepolia.inkonscan.xyz/](https://sepolia.inkonscan.xyz/) 21 | * API: [https://sepolia.inkonscan.xyz/documentation/api-swagger](https://sepolia.inkonscan.xyz/documentation/api-swagger) 22 | -------------------------------------------------------------------------------- /src/content/shared/bridges-content.mdx: -------------------------------------------------------------------------------- 1 | import { Callout } from 'nextra/components' 2 | 3 | # Bridges 4 | These bridges provide different interfaces to the canonical smart contracts that facilitate migrating ETH from one chain to another. 5 | 6 | 7 | Transaction times vary based on network congestion and gas fees. Please ensure you have enough ETH in your wallet to cover transaction fees. 8 | 9 | 10 | ##### How to use 11 | 1. Visit the bridge and connect your wallet. 12 | 2. Choose Sepolia as your source and Ink as the destination. 13 | 3. Input the amount of assets you want to bridge. 14 | 4. Confirm and sign the transaction with your wallet. 15 | 5. Once the bridging is complete, the assets will appear in your wallet on Ink. 16 | 17 | ## Gelato bridge 18 | Bridge: [https://bridge-gel-sepolia.inkonchain.com/](https://bridge-gel-sepolia.inkonchain.com/) 19 | 20 | ## Ink Bridge 21 | Bridge: [https://inkonchain.com/bridge](https://inkonchain.com/bridge) 22 | 23 | ## Brid.gg 24 | Bridge: [https://testnet.brid.gg/](https://testnet.brid.gg/) 25 | 26 | ## Superbridge 27 | Bridge: [https://superbridge.app/](https://superbridge.app/) (enable testnet in settings) 28 | -------------------------------------------------------------------------------- /src/content/shared/community-content.mdx: -------------------------------------------------------------------------------- 1 | import { URLS } from "@/utils/urls"; 2 | 3 | # Get Support 4 | 5 | Join the Ink community, vibe with fellow developers and get support: 6 | 7 | - Join the Ink Telegram for announcements: Join Telegram 8 | -------------------------------------------------------------------------------- /src/content/shared/crosschain-content.mdx: -------------------------------------------------------------------------------- 1 | # Crosschain Infrastructure 2 | 3 | ## Wormhole 4 | 5 | Wormhole is an interoperability platform powering multichain apps and bridges. 6 | 7 | * Wormhole currently supports Ink Sepolia. 8 | -------------------------------------------------------------------------------- /src/content/shared/faucets-content.mdx: -------------------------------------------------------------------------------- 1 | # Faucets 2 | 3 | Get Sepolia ETH on Ink from these faucets below! Alternatively, you can [bridge](https://inkonchain.com/bridge) testnet funds to Ink. 4 | 5 | ## [Ink](https://inkonchain.com/faucet) 6 | 7 | Our in-house faucet provides a quick and easy way to acquire testnet ETH. 8 | 9 | ## [Optimism Superchain Faucet](https://console.optimism.io/faucet) 10 | 11 | The Superchain Faucet provides testnet ETH for Ink and all other OP chains. Sign in to claim 0.10 test ETH on 1 network every 24 hours or verify your onchain identity for more tokens. 12 | 13 | ## [QuickNode](https://faucet.quicknode.com/drip) 14 | 15 | Use QuickNode Faucet to claim Ink Sepolia for testnet ETH for free - one drip per network every 12 hours. 16 | 17 | ## [Gelato](https://faucet-gel-sepolia.inkonchain.com) 18 | 19 | Gelato's Faucet uses Cloudflare authentication and drops up to 0.3 Ink Sepolia ETH every 12 hours. 20 | 21 | ## [Tenderly](https://tenderly.co/?mtm_campaign=ext-docs&mtm_kwd=ink) 22 | 23 | Tenderly's [Unlimited Faucet](https://docs.tenderly.co/virtual-testnets/unlimited-faucet?mtm_campaign=ext-docs&mtm_kwd=ink) allows you to mint native and ERC20 tokens for development and testing on Virtual TestNets. The unlimited faucet is part of the [Admin RPC](https://docs.tenderly.co/virtual-testnets/admin-rpc?mtm_campaign=ext-docs&mtm_kwd=ink), a collection of cheet-codes allowing full customization of the network. 24 | -------------------------------------------------------------------------------- /src/content/shared/multisig-content.mdx: -------------------------------------------------------------------------------- 1 | # Multisig 2 | 3 | ## Safe 4 | 5 | Ink hosts [Safe](https://docs.safe.global/home/what-is-safe)'s technology to bring digital ownership of accounts to everyone by building universal and open contract standards for the custody of digital assets, data, and identity. 6 | 7 | Using Safe you can: 8 | 9 | * Manage customizable non-custodial wallets supporting multisignatures for individuals and teams 10 | * Perform financial management of onchain assets incl. ERC20s, ERC721s and ETH 11 | * Access your safe using Web, Mobile and Desktop apps. 12 | * Safe also features access to DeFi, open source code, batch transactions, modular extensions, gasless signatures and more. 13 | 14 | **Supported Networks** 15 | 16 | * [Ink Mainnet](https://app.safe.global/new-safe/load?chain=ink) 17 | * [Ink Sepolia](https://safe.optimism.io/welcome/accounts?chain=ink-sepolia) 18 | -------------------------------------------------------------------------------- /src/fonts.ts: -------------------------------------------------------------------------------- 1 | import { Inter, Plus_Jakarta_Sans } from "next/font/google"; 2 | 3 | export const inter = Inter({ 4 | subsets: ["latin"], 5 | variable: "--font-inter", 6 | display: "swap", 7 | }); 8 | 9 | export const plus_jakarta_sans = Plus_Jakarta_Sans({ 10 | subsets: ["latin"], 11 | variable: "--font-plus-jakarta-sans", 12 | display: "swap", 13 | }); 14 | -------------------------------------------------------------------------------- /src/globals.css: -------------------------------------------------------------------------------- 1 | @tailwind base; 2 | @tailwind components; 3 | @tailwind utilities; 4 | 5 | @layer utilities { 6 | body { 7 | font-family: 8 | var(--font-plus-jakarta-sans), 9 | var(--font-inter), 10 | -apple-system, 11 | BlinkMacSystemFont, 12 | "Segoe UI", 13 | Helvetica, 14 | "Apple Color Emoji", 15 | Arial, 16 | sans-serif, 17 | "Segoe UI Emoji", 18 | "Segoe UI Symbol"; 19 | -webkit-font-smoothing: antialiased; 20 | -moz-osx-font-smoothing: grayscale; 21 | } 22 | } 23 | 24 | @layer base { 25 | h1, 26 | h2, 27 | h3, 28 | h4 { 29 | @apply !text-magic-deep-purple dark:!text-magic-white; 30 | } 31 | 32 | a:not(.nextra-sidebar-container a):not(nav a):not(.toc-link) { 33 | @apply !text-magic-purple dark:!text-magic-soft-pink !underline hover:!text-magic-purple/80 dark:hover:!text-magic-soft-pink/80; 34 | } 35 | 36 | nav > a { 37 | @apply !text-ink-grey-400 dark:!text-magic-white dark:hover:!text-ink-grey-400 hover:!text-ink-grey-700 !no-underline; 38 | } 39 | 40 | nav > a > svg { 41 | @apply !fill-magic-black dark:!fill-magic-white; 42 | } 43 | 44 | nav { 45 | @apply bg-white dark:bg-magic-black; 46 | } 47 | 48 | pre { 49 | @apply !bg-magic-semi-deep-purple/15; 50 | } 51 | 52 | .toc-link { 53 | @apply cursor-pointer !text-ink-grey-400 dark:!text-magic-white group-hover:!text-ink-grey-700 dark:group-hover:!text-ink-grey-700; 54 | } 55 | 56 | /* We need to override the underline for nav links and sidebar items */ 57 | nav > a, 58 | a:has(div.ink-sidebar-item), 59 | .toc-link { 60 | @apply no-underline; 61 | } 62 | } 63 | 64 | /* Some custom hacks to override some issues with Nextra */ 65 | .nextra-nav-container-blur { 66 | display: none !important ; 67 | } 68 | 69 | /* Remove the padding from the sidebar link, so that we can pply our own style */ 70 | a:has(div.ink-sidebar-item) { 71 | padding: 0 !important; 72 | background-color: transparent !important; 73 | } 74 | 75 | /* Target both the banner container and its text */ 76 | .nextra-banner-container { 77 | @apply text-white !important; 78 | } 79 | 80 | .nextra-banner-container a { 81 | @apply text-white hover:text-white/80 no-underline !important; 82 | } 83 | 84 | /* Override the purple link styles specifically for the banner */ 85 | .nextra-banner-container 86 | a:not(.nextra-sidebar-container a):not(nav a):not(.toc-link) { 87 | @apply text-white hover:text-white/80 underline !important; 88 | } 89 | 90 | /* Ensure all text in banner is white, not just links */ 91 | .nextra-banner-container { 92 | @apply text-white !important; 93 | } 94 | -------------------------------------------------------------------------------- /src/icons/Check.tsx: -------------------------------------------------------------------------------- 1 | export const CheckIcon: React.FC<{ className?: string }> = ({ 2 | className = "size-6", 3 | }) => { 4 | return ( 5 | 11 | 17 | 18 | ); 19 | }; 20 | -------------------------------------------------------------------------------- /src/icons/ConnectedPulse.tsx: -------------------------------------------------------------------------------- 1 | import clsx from "clsx"; 2 | 3 | export const ConnectedPulse: React.FC<{ className?: string }> = ({ 4 | className, 5 | }) => { 6 | return ( 7 | 8 | 9 | 10 | 11 | ); 12 | }; 13 | -------------------------------------------------------------------------------- /src/icons/Download.tsx: -------------------------------------------------------------------------------- 1 | interface PencilProps { 2 | className?: string; 3 | } 4 | 5 | export const DownloadIcon: React.FC = ({ 6 | className = "size-6", 7 | }) => { 8 | return ( 9 | 17 | 21 | 22 | ); 23 | }; 24 | -------------------------------------------------------------------------------- /src/icons/InkLogo.tsx: -------------------------------------------------------------------------------- 1 | import Image from "next/image"; 2 | import { useTheme } from "nextra-theme-docs"; 3 | 4 | interface InkLogoProps { 5 | className?: string; 6 | } 7 | 8 | export const InkLogo: React.FC = ({ 9 | className = "text-magic-purple", 10 | }) => { 11 | const { resolvedTheme } = useTheme(); 12 | const logoSrc = 13 | resolvedTheme === "dark" 14 | ? "/logo/ink-logo-dark.svg" 15 | : "/logo/ink-logo-light.svg"; 16 | 17 | return ( 18 | Ink logo 26 | ); 27 | }; 28 | -------------------------------------------------------------------------------- /src/icons/Moon.tsx: -------------------------------------------------------------------------------- 1 | interface MoonIconProps { 2 | className?: string; 3 | } 4 | 5 | export const MoonIcon: React.FC = ({ 6 | className = "w-6 h-6", 7 | }) => { 8 | return ( 9 | 15 | 21 | 22 | ); 23 | }; 24 | -------------------------------------------------------------------------------- /src/icons/Pencil.tsx: -------------------------------------------------------------------------------- 1 | interface PencilProps { 2 | className?: string; 3 | } 4 | 5 | export const PencilIcon: React.FC = ({ className = "size-6" }) => { 6 | return ( 7 | 15 | 20 | 21 | ); 22 | }; 23 | -------------------------------------------------------------------------------- /src/icons/Sun.tsx: -------------------------------------------------------------------------------- 1 | interface SunIconProps { 2 | className?: string; 3 | } 4 | 5 | export const SunIcon: React.FC = ({ className = "w-6 h-6" }) => { 6 | return ( 7 | 13 | 19 | 20 | ); 21 | }; 22 | -------------------------------------------------------------------------------- /src/icons/ThumbUp.tsx: -------------------------------------------------------------------------------- 1 | interface ThumbUpProps { 2 | className?: string; 3 | } 4 | 5 | export const ThumbUpIcon: React.FC = ({ 6 | className = "size-6", 7 | }) => { 8 | return ( 9 | 17 | 22 | 23 | ); 24 | }; 25 | -------------------------------------------------------------------------------- /src/images/add_network.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/add_network.png -------------------------------------------------------------------------------- /src/images/blockscout_verif_1_ink.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/blockscout_verif_1_ink.png -------------------------------------------------------------------------------- /src/images/blockscout_verif_2_ink.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/blockscout_verif_2_ink.png -------------------------------------------------------------------------------- /src/images/blockscout_verif_3_ink.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/blockscout_verif_3_ink.png -------------------------------------------------------------------------------- /src/images/gas_fees.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/gas_fees.png -------------------------------------------------------------------------------- /src/images/ink-banner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/ink-banner.png -------------------------------------------------------------------------------- /src/images/remix_deploy_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/remix_deploy_1.png -------------------------------------------------------------------------------- /src/images/remix_deploy_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/remix_deploy_2.png -------------------------------------------------------------------------------- /src/images/remix_deploy_3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/remix_deploy_3.png -------------------------------------------------------------------------------- /src/images/remix_deploy_4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/remix_deploy_4.png -------------------------------------------------------------------------------- /src/images/remix_deploy_5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/remix_deploy_5.png -------------------------------------------------------------------------------- /src/images/vrf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/inkonchain/docs/652657b80f055d91d9f050619ee944d0be5d088f/src/images/vrf.png -------------------------------------------------------------------------------- /src/pages/404.mdx: -------------------------------------------------------------------------------- 1 | # Page Not Found 2 | 3 | #### Return [home](/). 4 | 5 | #### Please help by [submitting an issue](https://github.com/inkonchain/docs/issues/new) for the broken link. 💜 6 | -------------------------------------------------------------------------------- /src/pages/500.mdx: -------------------------------------------------------------------------------- 1 | # Unexpected Error 2 | 3 | ![500 Error Warning.](/img/icons/500-page.svg) 4 | 5 | ## Something isn't quite right. Let's start again on the [homepage](index). 6 | 7 | #### Please help by [submitting an issue](https://github.com/inkonchain/docs/issues/new) for the broken link. ❤️ 8 | 9 | # CHANGE 10 | 11 | \n 12 | -------------------------------------------------------------------------------- /src/pages/_app.mdx: -------------------------------------------------------------------------------- 1 | import { ThemeProvider } from "next-themes"; 2 | import Script from "next/script"; 3 | import { inter, plus_jakarta_sans } from "../fonts"; 4 | import ClientOnlyAskCookbook from "../components/ClientOnlyAskCookbook"; 5 | import "../globals.css"; 6 | 7 | export default function App({ Component, pageProps }) { 8 | return ( 9 | 10 |