Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/apursley2012/cosmic-developer/llms.txt

Use this file to discover all available pages before exploring further.

The distributed Cosmic Developer repository is already the built output — it contains index.html, a compiled assets/ folder, pre-rendered pages/ stubs, and a .nojekyll file, ready to serve directly from any static host with zero additional build steps. This page explains how to deploy this repository as-is, and what changes are needed if you fork the source project and want to build your own version.
This repository contains no package.json, no vite.config.js, and no src/ directory — it is the compiled result of a Vite build, not the build source. Commands like npm install or npm run build apply only to a fork of the source project, not to this deployed repo.

What Is Already in the Repository

When you clone or fork this repository, you get everything a static host needs:
/
├── index.html          ← Application entry point
├── .nojekyll           ← Disables Jekyll on GitHub Pages
├── assets/
│   ├── main.js         ← Compiled, minified JavaScript bundle
│   ├── main.css        ← Compiled Tailwind + Google Fonts import
│   ├── jsx-runtime.js
│   ├── proxy.js
│   └── createLucideIcon.js
├── components/
│   └── cosmos/
│       ├── Navigation.js
│       ├── StarfieldBackground.js
│       ├── AuroraBackground.js
│       ├── CustomCursor.js
│       ├── Footer.js
│       ├── PageTransition.js
│       └── TeletypeText.js
└── pages/
    ├── About.html
    ├── Articles.html
    ├── CaseStudies.html
    ├── Contact.html
    ├── Projects.html
    ├── Skills.html
    ├── Testimonials.html
    └── Work.html
No build step is required. Upload the repository contents to your host and the site is live.

Deploy to a Hosting Platform

The repository ships with a .nojekyll file at the root, which tells GitHub Pages to skip Jekyll processing and serve all files (including those beginning with underscores) as-is. This is essential for Vite’s hashed asset filenames to resolve correctly.Option 1 — Deploy this repo directly
  1. Push or fork this repository to your GitHub account.
  2. Go to Settings → Pages in your repository.
  3. Under Build and deployment, set the source to Deploy from a branch, choose the main branch, and select the root (/) directory.
  4. Click Save. GitHub Pages will serve the repository root — your site will be live within a minute.
Option 2 — GitHub Actions (for source forks)If you have forked the source project and want to build and deploy automatically on every push, add the following workflow file at .github/workflows/deploy.yml. It installs dependencies, runs the Vite build, and publishes the dist/ output to the gh-pages branch.
name: Deploy to GitHub Pages

on:
  push:
    branches:
      - main

permissions:
  contents: write

jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v4

      - name: Set up Node.js
        uses: actions/setup-node@v4
        with:
          node-version: 18

      - name: Install dependencies
        run: npm install

      - name: Build
        run: npm run build

      - name: Deploy to gh-pages
        uses: peaceiris/actions-gh-pages@v4
        with:
          github_token: ${{ secrets.GITHUB_TOKEN }}
          publish_dir: ./dist
After the first successful run, go to Settings → Pages and set the source to the gh-pages branch, root directory.
If your repository is hosted at a subdirectory path (e.g. https://username.github.io/cosmic-developer/), set the base option in vite.config.js (in the source project) to match: base: '/cosmic-developer/'. See the Vite configuration section for details.

How Hash Routing Works on Static Hosts

Cosmic Developer uses React Router’s HashRouter, which prefixes all client-side routes with a # symbol — for example /#/about, /#/projects, /#/skills. This design choice makes the portfolio compatible with every static host without any server-side configuration. When a visitor navigates to https://yoursite.com/#/about, the browser sends a request for https://yoursite.com/ to the server. The #/about fragment is never transmitted to the server — it stays in the browser. The server returns index.html, React mounts, and React Router reads window.location.hash to render the correct page.
Browser → requests: https://yoursite.com/     (hash fragment stays local)
Server  → returns:  index.html
React   → reads:    window.location.hash = "#/about"
Router  → renders:  <About /> component
This means you never need 404 fallback rules, _redirects files, or try_files directives — the hash handles everything client-side.

Google Fonts Dependency

Cosmic Developer loads three typefaces — Inter, JetBrains Mono, and Space Grotesk — via a CSS @import baked into assets/main.css:
@import "https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=JetBrains+Mono:wght@400;700&family=Space+Grotesk:wght@400;600;700&display=swap";
This import fires at page load and requires an outbound internet connection. The fonts will silently fall back to system sans-serif and monospace fonts if the CDN is unreachable.
If you are deploying to a restricted or air-gapped environment where outbound internet access is blocked, the custom typefaces will not load and the visual design will degrade. To fix this, you will need to work from the source project: download the font files from Google Fonts, add them to the public/ folder, replace the @import in the source main.css with self-hosted @font-face declarations, and rebuild with npm run build.

Build docs developers (and LLMs) love