deno-fresh-llm-benchmark Svelte Themes

Deno Fresh Llm Benchmark

An LLM benchmark for Deno Fresh based on the OpenAI methodology from OpenAIs paper "Evaluating Large Language Models Trained on Code". Shamelessly stolen from https://github.com/khromov/svelte-bench

✨ NebulaKit

A cosmic-grade SvelteKit starter template powered by Cloudflare's full stack

NebulaKit is a production-ready SvelteKit template with everything you need to build modern web applications. It comes with Cloudflare Workers integration (D1, KV, R2, Queues, Turnstile), a complete theme system, command palette, LLM chat UI, full authentication, and polished drag-and-dropβ€”all built in from day one.

🌟 Features

  • πŸš€ Cloudflare Full Stack: D1 database, KV storage, R2 buckets, Queues, and Turnstile built-in
  • 🎨 Theme System: Light/dark modes with extensible CSS variables
  • ⌨️ Command Palette: Keyboard-first navigation (Cmd/Ctrl + K)
  • πŸ’¬ LLM Chat UI: Ready-to-use chat interface for AI integration
  • πŸ” Full Authentication: Email/password + SSO (Google, GitHub) with account linking
  • πŸ“± Mobile-First: Responsive layouts optimized for all devices
  • 🎯 Drag & Drop: Polished DnD with cross-column and mobile support
  • ⚑ TypeScript: Full type safety with Cloudflare Workers types
  • 🎨 UI Components: Beautiful, accessible components out of the box

πŸš€ Quick Start

# Install dependencies
npm install

# Start development server
npm run dev

# Build for production
npm run build

# Deploy to Cloudflare Pages
npm run deploy

Visit http://localhost:5173 to see your app!

πŸ§ͺ Testing (TDD Required!)

NebulaKit follows Test-Driven Development with 90%+ code coverage requirements:

# Run all tests
npm run test

# Run tests in watch mode
npm run test:watch

# Check coverage (must be β‰₯90%)
npm run test:coverage

# Run E2E tests
npm run test:e2e

# Run all tests (unit + E2E)
npm run test:all

Important: All features and bug fixes require tests written FIRST. See CONTRIBUTING.md for details.

πŸ“š Documentation

πŸ—οΈ Project Structure

NebulaKit/
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ lib/
β”‚   β”‚   β”œβ”€β”€ components/     # Reusable UI components
β”‚   β”‚   β”œβ”€β”€ stores/         # Svelte stores (theme, etc.)
β”‚   β”‚   β”œβ”€β”€ server/         # Server-side utilities
β”‚   β”‚   └── utils/          # Helper functions
β”‚   β”œβ”€β”€ routes/             # SvelteKit routes
β”‚   β”‚   β”œβ”€β”€ auth/          # Authentication pages
β”‚   β”‚   β”œβ”€β”€ chat/          # LLM chat interface
β”‚   β”‚   └── demo/          # Feature demonstrations
β”‚   β”œβ”€β”€ app.css            # Global styles & theme
β”‚   └── app.html           # HTML template
β”œβ”€β”€ static/                 # Static assets
└── wrangler.toml          # Cloudflare configuration

🎨 Theming

NebulaKit includes a comprehensive theme system with:

  • βœ… WCAG AA compliant colors (4.5:1 contrast minimum)
  • πŸŒ“ Light and dark modes with automatic system detection
  • 🎨 CSS custom properties for all design tokens
  • β™Ώ Accessibility-first design approach
  • πŸ§ͺ Automated contrast validation
/* All colors use CSS variables - never hardcode! */
.button {
    background-color: var(--color-primary);
    color: var(--color-background);
    border-radius: var(--radius-md);
    padding: var(--spacing-sm) var(--spacing-md);
}

Validate theme contrast:

npm run validate:contrast

See the Theme System Guide for complete documentation.

πŸ” Authentication

Built-in auth pages with support for:

  • Email/password authentication
  • OAuth providers (Google, GitHub)
  • Session management
  • Account linking

Easily extend with @auth/sveltekit for more providers.

πŸ’¬ Chat UI

The included chat interface is ready to connect to your LLM API:

// In /routes/chat/+page.svelte
async function sendMessage() {
    const response = await fetch('/api/chat', {
        method: 'POST',
        body: JSON.stringify({ message: input })
    });
    // Handle response
}

☁️ Cloudflare Integration

D1 Database

const result = await platform.env.DB.prepare('SELECT * FROM users WHERE email = ?')
    .bind(email)
    .first();

KV Storage

await platform.env.KV.put('key', 'value');
const value = await platform.env.KV.get('key');

R2 Storage

await platform.env.BUCKET.put('file.jpg', fileData);
const file = await platform.env.BUCKET.get('file.jpg');

Queues

await platform.env.QUEUE.send({ data: 'message' });

🎯 Drag & Drop

The demo page includes a fully functional kanban board with:

  • Desktop drag and drop
  • Mobile touch support
  • Cross-column dragging
  • Smooth animations

πŸ“± Mobile Support

NebulaKit is mobile-first with:

  • Responsive breakpoints (640px, 768px, 1024px, 1280px)
  • Touch-optimized interactions
  • Mobile navigation menu
  • Optimized bundle sizes

πŸ› οΈ Tech Stack

πŸ“ License

MIT License - feel free to use this template for any project!

🀝 Contributing

We welcome contributions! Please read our Contributing Guide first.

Key requirements:

  • βœ… Test-Driven Development (TDD) - write tests first
  • βœ… 90%+ code coverage on all changes
  • βœ… Cloudflare-first architecture
  • βœ… Minimal external dependencies
  • βœ… All tests passing before PR

See .github/copilot-instructions.md for detailed development guidelines.

⭐ Show Your Support

If you find NebulaKit useful, please consider giving it a star on GitHub!

Top categories

Loading Svelte Themes