The official website for Hackheim. This site serves as both a public-facing website and documentation platform, built with Astro and Starlight.
- Framework: Astro with Starlight for documentation
- UI Components: Svelte
- Styling: TailwindCSS
- Content: Markdown/MDX with content collections
- Deployment: Cloudflare Pages
- Package Manager: pnpm
- Node.js (version 18 or higher)
- pnpm (recommended package manager)
-
Clone the repository:
git clone https://github.com/hackheim/hackheimweb.git cd hackheim-web -
Install dependencies:
pnpm install
-
Start the development server:
pnpm dev
The site will be available at http://localhost:4321
.
βββ public/ # Static assets (favicons, images, etc.)
βββ src/
β βββ assets/ # Build-time assets (logos, etc.)
β βββ components/ # Reusable components
β β βββ starlight/ # Custom Starlight components
β βββ content/ # Content collections
β β βββ docs/ # Documentation pages
β β βββ news/ # News articles
β β βββ pages/ # General pages
β β βββ projects/ # Project showcases
β βββ layouts/ # Page layouts
β βββ pages/ # Route pages
β β βββ index.astro # Homepage
β β βββ news/ # News listing pages
β β βββ projects/ # Project listing pages
β βββ styles/ # Global styles
β βββ content.config.ts # Content collection schemas
βββ astro.config.mjs # Astro configuration
βββ wrangler.toml # Cloudflare deployment config
βββ package.json
Content is organized into collections defined in src/content.config.ts:
- docs: Documentation pages (Starlight integration)
- news: News articles and announcements
- projects: Project showcases and tutorials
- pages: General website pages
- Documentation: Add
.mdfiles tosrc/content/docs/ - News: Add
.mdfiles tosrc/content/news/with frontmatter - Projects: Add
.mdfiles tosrc/content/projects/with required schema - Pages: Add
.mdfiles tosrc/content/pages/
| Command | Description |
|---|---|
pnpm dev |
Start development server |
pnpm build |
Build for production |
pnpm preview |
Preview production build locally |
pnpm devdeploy |
Build and deploy to Cloudflare |
pnpm astro ... |
Run Astro CLI commands |
The site supports both Norwegian (default) and English:
- Default locale: Norwegian (
nb-NO) - Alternate locale: English (
en)
Content can be localized by adding language suffixes to files or using Starlight's built-in i18n features.
The site is deployed to Cloudflare Pages using Wrangler:
- Development deployment:
pnpm devdeploy - Production: Automatic deployment via GitHub integration
Configuration is managed through wrangler.toml.
- Fork the repository
- Create a feature branch
- Make your changes
- Test locally with
pnpm dev - Build to ensure no errors:
pnpm build - Submit a pull request
- GitHub: hackheim/hackheimweb
- Website: hackheim.no