GitHub Integration

Navieo connects directly to your GitHub repository to scan your codebase, discover routes, and extract interactive elements — all from the dashboard. No local tooling required.

Connecting Your Repository

  1. Go to your Navieo dashboard and open your app
  2. Navigate to Integrations → GitHub
  3. Click Connect Repository
  4. You'll be redirected to GitHub to install the Navieo GitHub App
  5. Authorize Navieo for your organization (or personal account)
  6. Select the repository that contains your application code
  7. Click Install & Authorize

Once connected, your repository name appears in the dashboard with a green "Connected" badge.

Permissions

The Navieo GitHub App requests minimal permissions:

PermissionScopeWhy
Repository contentsRead-onlyTo read your source code files for scanning
Pull requestsRead & WriteTo open PRs with scan results (.navieo/sitemap.json)
MetadataRead-onlyRequired by GitHub for all Apps

Navieo never modifies your source code. The only files it writes are inside the .navieo/ directory via Pull Requests that you review and merge.

Scanning Your Codebase

After connecting, go to the Scan page in your dashboard and click Scan Codebase. Navieo will:

  1. Detect your framework — Next.js App Router, Pages Router, or Vite
  2. Discover all routes — reads your app/ or pages/ directory structure via the GitHub API
  3. Extract interactive elements — finds buttons, links, inputs, and forms in each route using AST analysis
  4. Map selectors — generates CSS selectors using id, aria-label, data-navieo-id, and semantic attributes
  5. Build the knowledge base — stores the complete route and element map for the AI

The scan typically takes 5–30 seconds depending on repository size.

Enrich with AI

After scanning, click Enrich with AI to generate semantic descriptions for your routes and elements. This optional step:

  • Adds human-readable descriptions to each route (e.g., "User settings page with profile and notification preferences")
  • Describes what each interactive element does (e.g., "Opens the team invitation dialog")
  • Maps business context (e.g., "Billing is the revenue center. Plan upgrades take effect immediately.")
  • Improves tour quality by giving the AI richer understanding of your application

Enrichment runs once per scan and takes 10–45 seconds depending on route count.

Re-Scanning

Click Scan Codebase again at any time to refresh your knowledge base after code changes. Each scan is a full replacement — new routes appear and deleted routes are removed.

After a scan, Navieo opens a Pull Request on your repository with the updated .navieo/sitemap.json file. You can review and merge this PR to keep your repo in sync with the scan results.

Sync to GitHub

Click Sync to GitHub on the Scan page to force-push the latest scan results back to your repository as a PR. This is useful when the initial scan didn't trigger a PR (e.g., content was unchanged).

Supported Frameworks

FrameworkDetectionRoute Scanning
Next.js App Routerapp/ directory detectedapp/**/page.tsx files
Next.js Pages Routerpages/ directory detectedpages/**/*.tsx files
Vite / React SPAvite.config.* detectedGeneric component scanning

Configuration

You can customize scanning behavior by adding a .navieo/config.json file to your repository:

{
  "framework": "nextjs",
  "srcDir": "src",
  "ignore": ["src/admin/**", "src/internal/**"]
}
FieldDescriptionDefault
framework"nextjs", "nextjs-pages", "vite", or "unknown"Auto-detected from file structure
srcDirSource directory relative to repo root"src" if it exists, otherwise ""
ignoreGlob patterns to exclude from scanningTest files, __tests__, node_modules

If this file doesn't exist, Navieo uses sensible defaults.

Dashboard → GitHub Sync

When you edit docs in the Navieo dashboard, changes are automatically synced back to your repository:

  • Docs saved in the dashboard create or update .navieo/docs/{slug}.md files via PR
  • Scan results are written to .navieo/sitemap.json via PR

You can configure the sync mode in your GitHub settings:

ModeBehavior
PR (default)Changes open a Pull Request for review
DirectChanges commit directly to the default branch

Subsequent saves push new commits to the same open PR instead of creating new ones (no PR spam).

Disconnecting

To disconnect your repository:

  1. Go to Integrations → GitHub in your dashboard
  2. Click Disconnect

This removes the GitHub connection but does not delete your existing scan data. Tours continue to work with the last scan results. You can reconnect the same or a different repository at any time.

Webhook Events

When your repo is connected, Navieo automatically processes these GitHub events:

EventWhat Navieo Does
Push to .navieo/sitemap.jsonRe-embeds the sitemap for tour generation
Push to .navieo/docs/*.mdSyncs doc pages to the dashboard
App installation/uninstallationUpdates connection status

Improving Selector Quality

For the best tour highlighting accuracy, add data-navieo-id attributes to key interactive elements in your code:

<button data-navieo-id="create-project">Create Project</button>
<input data-navieo-id="search-bar" placeholder="Search..." />

This gives Navieo a stable, high-confidence selector that won't break when CSS classes or component structure changes. It's optional — Navieo also uses id, aria-label, name, and semantic CSS selectors — but data-navieo-id is the most reliable.