web3privacy now

Documentation

Data structure

Overview of where data and content live in the Portal monorepo and org web.

Monorepo layout

PORTAL/
├── apps/
│   └── web/                 # Next.js portal (news, explorer, stacks, academy, events, …)
├── w3pn-org-web/            # Org website (Vite + React) + integrated docs
├── data/                    # Shared data (e.g. news crawler output)
│   └── docs/                # Docs content (fetched from web3privacy/docs + local)
└── scripts/                 # Build and fetch scripts

Org web (w3pn-org-web)

  • Content / CMS: src/data/defaultContent.js — nav, hero, footer, about, projects list, etc. Editable via admin panel.
  • Docs: Served from public/data/docs/ (URL path /data/docs/). Markdown/MDX files plus sidebar.json and manifest.json. Fetched from web3privacy/docs via scripts/fetch-docs-from-github.mjs; local overrides and Portal & Org Web pages live in the same tree.
  • Projects data: Project definitions (hero, mission, links) are in defaultContent or imported from a central list used by the portal.

Portal (apps/web)

  • Data sources: Next.js app reads from repo data, APIs, and env. Key areas:
    • News: data/news/ (crawler output, overrides), API routes under app/api/news/.
    • Explorer / projects: API routes and data used by explorer and project pages.
    • Events, people, academy, jobs: Own data or API routes as defined in the app.

Docs (data/docs / public/data/docs)

  • Location: In org web, files live under w3pn-org-web/public/data/docs/ so they are served at /data/docs/.
  • Structure: Mirrors web3privacy/docs src/content/docs/ (e.g. about-us/, research/, contributors/, portal-and-org-web/).
  • sidebar.json: Defines left navigation (categories and links). Link targets are slugs (e.g. about-us/culture, portal-and-org-web/index).
  • manifest.json: Generated by the fetch script; maps slug → file path for resolution. Optional for static builds.
  • Images: Docs repo references assets under src/content/docs/assets/. For now, image paths may point to relative paths or upstream; asset sync can be added later.

Updating docs

  1. From upstream: Run node scripts/fetch-docs-from-github.mjs from repo root to refresh content from web3privacy/docs main.
  2. Local edits: Edit Markdown under w3pn-org-web/public/data/docs/ (or under data/docs if you later move to a single source). Do not push these back to GitHub until the full portal release; the fetch script and structure are prepared for future sync.