Coding
PromptBeginner5 minmarkdown
Markdown Converter
Agent skill for markdown-converter
7
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
Sign in to like and favorite skills
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
Celestite is a Crystal library that enables server-side rendering (SSR) of Svelte 5 components. It spawns a Bun/Vite render server that handles SSR requests via HTTP, allowing Crystal web applications to use Svelte as their view layer.
shards install # Installs Crystal deps and runs bun install via postinstall hook
crystal spec # Run all tests crystal spec spec/celestite_spec.cr # Run specific test file
# From svelte-scripts directory with proper env vars: make build COMPONENT_DIR=/path/to/views BUILD_DIR=/path/to/public/celestite
The project is a shard (Crystal library) - no standalone run command. Tests spawn a Bun SSR server that must start within 20 seconds.
src/celestite/)celestite_render macro for Amber and Kemal.src/svelte-scripts/)development, development_secure, staging, production, build.Celestite.render(component, context)Celestite.initialize( engine: Celestite::Engine::Svelte, component_dir: "./src/views/", # Svelte components build_dir: "./public/celestite/", # Output for client bundles port: 4000, # Bun SSR server port vite_port: 5173, # Vite dev server port (development only) dev_secure: false, # Enable HTTPS mode disable_a11y_warnings: false # Suppress Svelte a11y warnings )
Tests start actual Bun processes. The
run_spec_server helper in spec/spec_helper.cr handles server lifecycle with timeout handling. Tests wait for "SSR renderer listening" in output before proceeding.