├── .circleci └── config.yml ├── .coderabbit.yaml ├── .eslintignore ├── .eslintrc.js ├── .github └── CODEOWNERS ├── .gitignore ├── .npmrc ├── README.md ├── cspell.json ├── lychee.toml ├── next-env.d.ts ├── next-sitemap.config.js ├── next.config.mjs ├── notes ├── README.md ├── actions.md ├── nextra.md └── remark.md ├── package.json ├── pages ├── 404.mdx ├── 500.mdx ├── _app.tsx ├── _document.tsx ├── _meta.json ├── citizens-house │ ├── _meta.json │ ├── citizen-house-overview.mdx │ ├── citizen-selection-glossary │ ├── citizenship-selection.mdx │ ├── experimentation-with-citizenship.mdx │ ├── how-retro-funding-works.mdx │ └── rounds │ │ ├── _meta.json │ │ ├── retropgf-1.mdx │ │ ├── retropgf-2.mdx │ │ ├── retropgf-3.mdx │ │ ├── retropgf-4.mdx │ │ ├── retropgf-5.mdx │ │ └── retropgf-6.mdx ├── connect │ └── _meta.json ├── contribute │ ├── _meta.json │ ├── contribute-overview.mdx │ ├── contribution-path │ │ ├── _meta.json │ │ ├── ambassador-req.mdx │ │ ├── govnerds.mdx │ │ ├── local-optimists.mdx │ │ ├── numbanerds.mdx │ │ ├── supnerd-requirements.mdx │ │ ├── technerds.mdx │ │ └── translators.mdx │ ├── demo-day.mdx │ ├── important-terms.mdx │ └── technical-contributions.mdx ├── grant │ ├── _meta.json │ ├── get-support.mdx │ └── grant-overview.mdx ├── identity │ ├── _meta.json │ ├── about-attestations.mdx │ ├── applications.mdx │ ├── attestations-best-practices.mdx │ ├── contracts-eas.mdx │ ├── identity-and-rep.mdx │ ├── individuals.mdx │ ├── organizations.mdx │ ├── overview.mdx │ ├── project-and-individual-identity.mdx │ ├── projects.mdx │ └── schemas.mdx ├── index.mdx ├── op-token │ ├── _meta.json │ ├── airdrops │ │ ├── _meta.json │ │ ├── airdrop-1.mdx │ │ ├── airdrop-2.mdx │ │ ├── airdrop-3.mdx │ │ ├── airdrop-4.mdx │ │ └── airdrop-5.mdx │ ├── op-token-overview.mdx │ └── superstacks.mdx ├── research │ ├── _meta.json │ └── research-overview.mdx ├── token-house │ ├── _meta.json │ ├── delegate-expectations.mdx │ ├── gov-fund-overview.mdx │ ├── how-to-delegate.mdx │ ├── token-house-history.mdx │ └── token-house-overview.mdx └── welcome │ ├── _meta.json │ ├── faq │ ├── _meta.json │ ├── dashboard-trackers.mdx │ └── what-is-the-optimism-foundation.mdx │ ├── governing-docs │ ├── _meta.json │ └── law-of-chains-disclaimer.mdx │ └── welcome-overview.mdx ├── patches ├── nextra@2.13.2.patch ├── remark-code-import@1.2.0.patch └── remark-lint-frontmatter-schema@3.15.4.patch ├── pnpm-lock.yaml ├── public ├── _redirects ├── grafana │ └── dispute-monitor-1718214549035.json ├── img │ ├── citizen-house │ │ ├── how-retro-funding-works.png │ │ ├── reward-impact.jpg │ │ └── scientific-method.png │ ├── contribute │ │ └── att-framework.png │ ├── grant │ │ ├── grant-options.png │ │ ├── intents.png │ │ ├── measuring-missions.png │ │ ├── missions-graphic.png │ │ └── season-7-intent.png │ ├── icons │ │ ├── 404-page.svg │ │ ├── 500-page.svg │ │ ├── arrow-left-right.svg │ │ ├── arrow-up-double.png │ │ ├── asterisk.svg │ │ ├── book.svg │ │ ├── build.svg │ │ ├── computer-line.svg │ │ ├── favicon.ico │ │ ├── file-edit-line.svg │ │ ├── gear.svg │ │ ├── government-line.svg │ │ ├── info.png │ │ ├── instance-line.svg │ │ ├── link.svg │ │ ├── news-line.svg │ │ ├── person.svg │ │ ├── profile.png │ │ ├── question-answer-line.svg │ │ ├── rocket-2-line.svg │ │ ├── shapes.svg │ │ ├── stack-line.svg │ │ ├── stack.svg │ │ ├── terminal-window-line.svg │ │ ├── tools.svg │ │ ├── wallet.png │ │ └── wallet.svg │ ├── identity │ │ ├── atst-logo.png │ │ ├── profile.png │ │ └── upload_b344e96d086ccbeeb28b3609a8fdbf92.png │ ├── op-mainnet │ │ └── identity │ │ │ ├── atst-logo.png │ │ │ └── profile.png │ ├── op-token │ │ └── op-token-allocation.jpeg │ ├── research │ │ ├── experiment-principles.png │ │ └── experiment.png │ └── welcome │ │ ├── high-level-gov-houses.svg │ │ └── two-houses-responsibilities.png ├── logos │ ├── docs-header.png │ ├── favicon.png │ ├── header.png │ ├── icon-1020x1020.png │ ├── icon-192x192.png │ ├── icon-256x256.png │ ├── icon-384x384.png │ ├── icon-512x512.png │ ├── logo-docs-dark.svg │ ├── logo-docs-light.svg │ ├── twitter-logo.png │ └── twitter-superchain.png ├── service-worker.js └── tutorials │ ├── cross-dom-bridge-erc20.js │ ├── cross-dom-bridge-eth.js │ ├── cross-dom-solidity.js │ ├── cross-dom-solidity.sol │ ├── first-contract.sol │ ├── sdk-estimate-costs.js │ ├── sdk-stack.js │ ├── sdk-trace-txns.js │ ├── sdk-view-txns.js │ ├── send-tx-from-eth.js │ ├── standard-bridge-custom-token.sol │ └── standard-bridge-standard-token.sh ├── styles ├── colors.css ├── global.css └── theme.css ├── theme.config.tsx ├── tsconfig.json ├── utils ├── constants.ts ├── gtag.ts ├── networks.ts ├── plugins │ └── remark │ │ └── remark-lint-no-blocked-characters.mjs └── schemas │ └── page.schema.yaml └── words.txt /.circleci/config.yml: -------------------------------------------------------------------------------- 1 | version: 2.1 2 | 3 | jobs: 4 | check-links: 5 | docker: 6 | - image: cimg/base:stable 7 | steps: 8 | - checkout 9 | - run: 10 | name: Install Lychee 11 | command: | 12 | curl -L https://github.com/lycheeverse/lychee/releases/download/v0.14.3/lychee-v0.14.3-x86_64-unknown-linux-gnu.tar.gz > lychee.tar.gz 13 | tar xzf lychee.tar.gz 14 | sudo mv ./lychee /usr/local/bin/ 15 | - run: 16 | name: Run Lychee 17 | command: | 18 | lychee --config lychee.toml --quiet ./pages 19 | if [ $? -ne 0 ]; then 20 | echo "Lychee found broken links" 21 | exit 1 22 | fi 23 | lint-markdown: 24 | docker: 25 | - image: cimg/node:20.10 26 | steps: 27 | - checkout 28 | - run: 29 | name: Install pnpm 30 | command: sudo npm install -g pnpm 31 | - restore_cache: 32 | keys: 33 | - pnpm-deps-{{ checksum "pnpm-lock.yaml" }} 34 | - pnpm-deps- 35 | - run: 36 | name: Install Dependencies 37 | command: pnpm install 38 | - save_cache: 39 | key: pnpm-deps-{{ checksum "pnpm-lock.yaml" }} 40 | paths: 41 | - ~/.pnpm-store 42 | - run: 43 | name: Run lint 44 | command: pnpm lint 45 | 46 | check-lockfile: 47 | docker: 48 | - image: cimg/node:20.10 49 | steps: 50 | - checkout 51 | - run: 52 | name: Install pnpm 53 | command: sudo npm install -g pnpm 54 | - run: 55 | name: Install Dependencies 56 | command: pnpm install 57 | - run: 58 | name: Check lockfile 59 | command: | 60 | git diff --exit-code 61 | if [ $? -ne 0 ]; then 62 | echo "Lockfile is out of sync. Please run 'pnpm install' and commit the changes." 63 | exit 1 64 | fi 65 | 66 | workflows: 67 | version: 2 68 | check-links-workflow: 69 | jobs: 70 | - check-links 71 | 72 | lint-markdown-workflow: 73 | jobs: 74 | - lint-markdown 75 | 76 | check-lockfile-workflow: 77 | jobs: 78 | - check-lockfile 79 | -------------------------------------------------------------------------------- /.coderabbit.yaml: -------------------------------------------------------------------------------- 1 | language: "en" 2 | early_access: false 3 | reviews: 4 | high_level_summary: false 5 | poem: false 6 | review_status: false 7 | collapse_walkthrough: false 8 | path_instructions: 9 | - path: "**/*.mdx" 10 | instructions: | 11 | "ALWAYS review Markdown content THOROUGHLY with the following criteria: 12 | - Use proper nouns in place of personal pronouns like 'We' and 'Our' to maintain consistency in communal documentation. 13 | - Avoid gender-specific language and use the imperative form. 14 | - Monitor capitalization for emphasis. Use **bold** for prominence instead of all caps or italics. 15 | - Ensure proper nouns are capitalized in sentences. 16 | - Apply the Oxford comma. 17 | - Use proper title case for headers, buttons, tab names, page names, and links. Sentence case should be used for body content and short phrases, even in links. 18 | - Use correct spelling and grammar at all times (IMPORTANT). 19 | " 20 | auto_review: 21 | enabled: true 22 | drafts: false 23 | base_branches: 24 | - "main" 25 | chat: 26 | auto_reply: true -------------------------------------------------------------------------------- /.eslintignore: -------------------------------------------------------------------------------- 1 | pages/_app.mdx 2 | public/_redirects 3 | -------------------------------------------------------------------------------- /.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | parserOptions: { 3 | ecmaVersion: 'latest' 4 | }, 5 | extends: [ 6 | 'plugin:mdx/recommended', 7 | ], 8 | rules: { 9 | 'semi': ['error', 'never'] 10 | }, 11 | overrides: [ 12 | { 13 | files: ['pages/**/*.mdx'], 14 | extends: [ 15 | 'plugin:mdx/recommended' 16 | ], 17 | settings: { 18 | 'mdx/code-blocks': true 19 | }, 20 | rules: { 21 | 'no-unused-expressions': 'off', 22 | 'semi': ['error', 'never'] 23 | } 24 | } 25 | ] 26 | } -------------------------------------------------------------------------------- /.github/CODEOWNERS: -------------------------------------------------------------------------------- 1 | * @Nicca42 @opmxwell @opjulian @cpengilly @krofax @bradleycamacho 2 | -------------------------------------------------------------------------------- /.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 -------------------------------------------------------------------------------- /.npmrc: -------------------------------------------------------------------------------- 1 | enable-pre-post-scripts=true -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Optimism Community Hub 2 | 3 | This repo houses the Optimism Community Hub located at [community.optimism.io](https://community.optimism.io/). All documentation-related updates and new content will be tracked and maintained in this repo. 4 | 5 | ## Local Development 6 | 7 | How to [install pnpm](https://pnpm.io/installation) 8 | 9 | First, run `pnpm i` to install the dependencies. 10 | 11 | Then, run `pnpm dev` to start the development server and visit localhost:3000. 12 | 13 | ## Contributions 14 | 15 | Please see the [CONTRIBUTING.md](https://github.com/ethereum-optimism/docs/blob/main/CONTRIBUTING.md) page for specifics on how to write PRs, use the linter, run spellcheck, add dictionary terms, etc. You should also review the [Optimism Documentation Style Guide](/pages/connect/contribute/style-guide.mdx) for additional guidelines, especially if you are writing entirely brand new pages to the developer docs, as opposed to smaller edits and/or revisions. 16 | 17 | ## Project Board 18 | 19 | You can track documentation [issues](https://github.com/ethereum-optimism/community-hub/issues) or submit documentation [requests](https://github.com/ethereum-optimism/community-hub/issues/new/choose) directly from this repo. 20 | 21 | ## License 22 | 23 | This project is licensed under the MIT License. 24 | 25 | -------------------------------------------------------------------------------- /cspell.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://raw.githubusercontent.com/streetsidesoftware/cspell/main/packages/cspell-types/cspell.schema.json", 3 | "version": "0.2", 4 | "dictionaryDefinitions": [ 5 | { 6 | "name": "words", 7 | "path": "./words.txt", 8 | "addWords": true 9 | } 10 | ], 11 | "dictionaries": [ 12 | "words" 13 | ], 14 | "ignorePaths": [ 15 | "node_modules", 16 | "./words.txt" 17 | ], 18 | "overrides": [ 19 | { 20 | "filename": "**/*.mdx", 21 | "ignoreRegExpList": [ 22 | "/`[^`]*`/", 23 | "/```[\\s\\S]*?```/", 24 | "/\\([^)]*\\)/" 25 | ] 26 | } 27 | ] 28 | } 29 | -------------------------------------------------------------------------------- /lychee.toml: -------------------------------------------------------------------------------- 1 | ############################# Display ############################# 2 | # Use error level to only show failed requests 3 | verbose = "error" 4 | # Don't show interactive progress bar while checking links. 5 | no_progress = true 6 | # Don't show the source file of links 7 | no_show_source = false 8 | 9 | ############################# Requests ############################ 10 | # URL remapping rules. 11 | remap = [ 12 | # Handle resource files without adding .mdx extension 13 | "file:///pages/(.*?)\\.(pdf|png|jpg|jpeg|gif|svg|json)$ file:///./pages/$1.$2", 14 | # Handle URL-encoded anchors (%23) for mdx files 15 | "file:///([^%\\.]+)%23(.*) file:///./pages/$1.mdx#$2", 16 | # Handle regular anchors (#) for mdx files 17 | "file:///([^#\\.]+)#(.*) file:///./pages/$1.mdx#$2", 18 | # Handle regular mdx files without anchors 19 | "file:///([^#%\\.]+)$ file:///./pages/$1.mdx", 20 | ] 21 | 22 | # Base URL or website root directory to check relative URLs 23 | base = "." 24 | 25 | ############################# Exclusions ########################## 26 | # Exclude loopback IP address range and localhost from checking. 27 | exclude_loopback = true 28 | # Exclude all mail addresses from checking. 29 | exclude_mail = true 30 | # Exclude RPC URLs from checking 31 | exclude = [ 32 | 'https://mainnet.optimism.io', 33 | 'https://mainnet-sequencer.optimism.io', 34 | 'https://sepolia.optimism.io', 35 | 'https://sepolia-sequencer.optimism.io', 36 | 'https://archive.org', 37 | 'https://web.archive.org', 38 | 'https://mainnet.base.org', 39 | 'https://sepolia.base.org', 40 | 'https://optimism.easscan.org', 41 | '\.(pdf|zip|png|jpg|jpeg|gif|svg|json)$' 42 | ] 43 | 44 | # Accept all status codes except 404 45 | accept = [ 46 | "100..=399", 47 | "401..=403", 48 | "405..=999" 49 | ] 50 | 51 | # Use compact format for cleaner output 52 | 53 | format = "Compact" 54 | 55 | ############################# Anchors ############################# 56 | # Enable checking for anchors in local files 57 | check_anchors = true -------------------------------------------------------------------------------- /next-env.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | /// 3 | 4 | // NOTE: This file should not be edited 5 | // see https://nextjs.org/docs/basic-features/typescript for more information. 6 | -------------------------------------------------------------------------------- /next-sitemap.config.js: -------------------------------------------------------------------------------- 1 | /** @type {import('next-sitemap').IConfig} */ 2 | module.exports = { 3 | siteUrl: process.env.SITE_URL || 'https://snazzy-hamster-4e1647.netlify.app/', 4 | generateRobotsTxt: true, // (optional) 5 | generateIndexSitemap: true, 6 | // ...other options 7 | } 8 | -------------------------------------------------------------------------------- /next.config.mjs: -------------------------------------------------------------------------------- 1 | import nextra from 'nextra' 2 | import remarkCodeImport from 'remark-code-import' 3 | 4 | const withNextra = nextra({ 5 | theme: 'nextra-theme-docs', 6 | themeConfig: './theme.config.tsx', 7 | defaultShowCopyCode: true, 8 | mdxOptions: { 9 | remarkPlugins: [ 10 | remarkCodeImport, 11 | ] 12 | } 13 | }) 14 | 15 | export default { 16 | ...withNextra(), 17 | eslint: { 18 | ignoreDuringBuilds: true, 19 | }, 20 | } 21 | -------------------------------------------------------------------------------- /notes/README.md: -------------------------------------------------------------------------------- 1 | # Optimism Docs Docs 2 | 3 | The Optimism Docs Docs are internal docs to help you understand how the Optimism Docs are built and maintained. 4 | 5 | - [How the Optimism Docs Use Nextra](./nextra.md) 6 | - [How the Optimism Docs Use Remark](./remark.md) 7 | - [GitHub Actions](./actions.md) 8 | -------------------------------------------------------------------------------- /notes/actions.md: -------------------------------------------------------------------------------- 1 | # GitHub Actions 2 | 3 | ## Linting 4 | 5 | The `lint.yml` workflow checks that all Markdown and JavaScript files conform to the linting standards we apply. 6 | Run `pnpm lint` to lint locally and run `pnpm fix` to fix issues that the linter can fix automatically. 7 | All PRs must pass this check. 8 | Also includes spellchecking via [cspell](https://cspell.org/). 9 | 10 | ## Link Checks 11 | 12 | The `links.yml` workflow checks that all links in the docs are available. 13 | Runs once per day. 14 | 15 | ## Tutorial Checks 16 | 17 | The `tutorials.yml` workflow runs several of the tutorials within these docs. 18 | Most tutorials take the form of JavaScript files that are imported within the content of the docs. 19 | Same files can be executed individually to make sure that the tutorial actually works and isn't broken for one reason or another. 20 | -------------------------------------------------------------------------------- /notes/nextra.md: -------------------------------------------------------------------------------- 1 | # How the Optimism Docs Use Nextra 2 | 3 | The Optimism Docs use the [Nextra](https://nextra.site/) documentation framework. 4 | Nextra is essentially a combination of [Next.js](https://nextjs.org/) + [MDX](https://mdxjs.com/) and allows you to write React components that can be used within Markdown pages. 5 | Nextra documentation is decent and can explain the basics of how to do most of the things you might want to do. 6 | This page documents all of the things that we do that are currently not made obvious by Nextra's docs. 7 | 8 | ## Remark Plugins 9 | 10 | Nextra uses [Remark](https://github.com/remarkjs/remark) as a markdown processor. 11 | Remark plugins can be injected into Nextra by modifying the `mdxOptions` object inside of [`next.config.mjs`](/next.config.mjs). 12 | 13 | ### Custom Plugins 14 | 15 | #### remarkCodeImport 16 | 17 | Rule is modified via [patch](/patches/remark-code-import@1.2.0.patch) to require that all code imports include a md5 content hash of the imported content. 18 | Requiring this hash means that changes to the underlying content must also come with corresponding changes to the relevant imports and imports cannot silently break. 19 | -------------------------------------------------------------------------------- /notes/remark.md: -------------------------------------------------------------------------------- 1 | # How the Optimism Docs Use Remark 2 | 3 | The Optimism Docs use [Nextra](https://nextra.site) as a documentation framework which uses [Remark](https://github.com/remarkjs/remark) as a markdown processor under the hood. 4 | This repository also uses [ESLint](https://eslint.org) in combination with [`eslint-plugin-mdx`](https://www.npmjs.com/package/eslint-plugin-mdx) as this plugin also uses Remark under the hood. 5 | Remark is a flexible Markdown processor with a [vibrant plugin ecosystem](https://github.com/remarkjs/remark/blob/main/doc/plugins.md#list-of-plugins). 6 | 7 | ## Linting 8 | 9 | ### Adding Rules 10 | 11 | To add a linting rule, simply install your desired linting rule via `pnpm` and add the rule to the [`.remarkrc.mjs`](/.remarkrc.mjs) configuration file at the root of this repository. 12 | You can find a list of rules maintained by the Remark team on the [`remark-lint`](https://github.com/remarkjs/remark-lint#rules) repository. 13 | If you need to write your own custom plugin, place the plugin inside of [`utils/plugins/remark`](/utils/plugins/remark/) 14 | 15 | ### Custom Rules 16 | 17 | #### remarkLintNoBlockedCharacters 18 | 19 | Custom rule to prevent the use of certain characters like zero-width spaces or smartquotes. 20 | 21 | #### remarkLintFrontmatterSchema 22 | 23 | Rule is modified via [patch](/patches/remark-lint-frontmatter-schema@3.15.4.patch) to block MDX files from including no frontmatter at all. 24 | Pending [this issue](https://github.com/JulianCataldo/remark-lint-frontmatter-schema/issues/28) on GitHub. 25 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "op-docs", 3 | "version": "0.0.1", 4 | "description": "Optimism Docs", 5 | "packageManager": "pnpm@9.1.0", 6 | "scripts": { 7 | "lint": "eslint . --ext mdx --max-warnings 0 && pnpm spellcheck:lint", 8 | "fix": "eslint . --ext mdx --fix && pnpm spellcheck:fix", 9 | "spellcheck:lint": "cspell lint \"**/*.mdx\"", 10 | "spellcheck:fix": "cspell --words-only --unique \"**/*.mdx\" | sort --ignore-case | uniq > words.txt", 11 | "linkcheck": "lychee --config ./lychee.toml --quiet \"./pages\"", 12 | "dev": "next dev", 13 | "build": "next build", 14 | "start": "next start", 15 | "postbuild": "next-sitemap" 16 | }, 17 | "dependencies": { 18 | "@eth-optimism/contracts-ts": "^0.17.0", 19 | "@eth-optimism/tokenlist": "^9.0.9", 20 | "@feelback/react": "^0.3.4", 21 | "next": "14.1.1", 22 | "next-sitemap": "^4.2.3", 23 | "nextra": "2.13.2", 24 | "nextra-theme-docs": "2.13.2", 25 | "react": "^18.2.0", 26 | "react-dom": "^18.2.0" 27 | }, 28 | "devDependencies": { 29 | "@double-great/remark-lint-alt-text": "^1.0.0", 30 | "@eth-optimism/core-utils": "^0.13.1", 31 | "@eth-optimism/sdk": "^3.1.6", 32 | "@types/node": "18.11.10", 33 | "cspell": "^8.1.3", 34 | "eslint": "^8.53.0", 35 | "eslint-plugin-mdx": "^2.2.0", 36 | "ethers": "^5", 37 | "remark": "^15.0.1", 38 | "remark-code-import": "^1.2.0", 39 | "remark-frontmatter": "^5.0.0", 40 | "remark-gfm": "^3.0.1", 41 | "remark-lint-frontmatter-schema": "^3.15.4", 42 | "remark-lint-heading-style": "^3.1.2", 43 | "remark-lint-list-item-indent": "^3.1.2", 44 | "remark-lint-table-cell-padding": "^4.1.3", 45 | "remark-lint-table-pipe-alignment": "^3.1.3", 46 | "remark-lint-table-pipes": "^4.1.2", 47 | "remark-lint-unordered-list-marker-style": "^3.1.2", 48 | "remark-preset-lint-consistent": "^5.1.2", 49 | "remark-preset-lint-recommended": "^6.1.3", 50 | "typescript": "^5.2.2", 51 | "unified-lint-rule": "^2.1.2", 52 | "unist-util-visit": "^5.0.0" 53 | }, 54 | "pnpm": { 55 | "patchedDependencies": { 56 | "remark-lint-frontmatter-schema@3.15.4": "patches/remark-lint-frontmatter-schema@3.15.4.patch", 57 | "remark-code-import@1.2.0": "patches/remark-code-import@1.2.0.patch", 58 | "nextra@2.13.2": "patches/nextra@2.13.2.patch" 59 | } 60 | } 61 | } 62 | -------------------------------------------------------------------------------- /pages/404.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Page Not Found 3 | lang: en-US 4 | description: 404 page not found and directs users to submit an git issue. 5 | --- 6 | 7 | # Page Not Found 8 | 9 | ![404 Error Warning.](/img/icons/404-page.svg) 10 | 11 | ## Let's find our way back.
Visit the [homepage](index) to get started. 12 | 13 | ### Please help by [submitting an issue](https://github.com/ethereum-optimism/community-hub/issues/new/choose) for the broken link. ❤️ 14 | 15 | -------------------------------------------------------------------------------- /pages/500.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | title: Internal Server Error 3 | lang: en-US 4 | description: 500 internal server error and directs users to submit an git issue. 5 | --- 6 | 7 | # Unexpected Error 8 | 9 | ![500 Error Warning.](/img/icons/500-page.svg) 10 | 11 | ## Something isn't quite right. Let's start again on the [homepage](index). 12 | 13 | ### Please help by [submitting an issue](https://github.com/ethereum-optimism/community-hub/issues/new/choose) about what led you to this page. ❤️ 14 | -------------------------------------------------------------------------------- /pages/_app.tsx: -------------------------------------------------------------------------------- 1 | import '../styles/global.css' 2 | 3 | import { useEffect } from 'react' 4 | import { useRouter } from 'next/router' 5 | import * as gtag from '../utils/gtag' 6 | 7 | export default function App({ Component, pageProps }) { 8 | const router = useRouter() 9 | useEffect(() => { 10 | const handleRouteChange = (url) => { 11 | gtag.pageview(url) 12 | } 13 | router.events.on('routeChangeComplete', handleRouteChange) 14 | return () => { 15 | router.events.off('routeChangeComplete', handleRouteChange) 16 | } 17 | }, [router.events]) 18 | 19 | return 20 | } 21 | -------------------------------------------------------------------------------- /pages/_document.tsx: -------------------------------------------------------------------------------- 1 | import Document, { Html, Head, Main, NextScript } from 'next/document' 2 | 3 | import { GA_TRACKING_ID } from '../utils/gtag' 4 | 5 | export default class MyDocument extends Document { 6 | render() { 7 | return ( 8 | 9 | 10 | {/* Global Site Tag (gtag.js) - Google Analytics */} 11 |