Website rebuilt from scratch based on analysis of 11 beloved language websites (Elm, Zig, Gleam, Swift, Kotlin, Haskell, OCaml, Crystal, Roc, Rust, Go). New website structure: - Homepage with hero, playground, three pillars, install guide - Language Tour with interactive lessons (hello world, types, effects) - Examples cookbook with categorized sidebar - API documentation index - Installation guide (Nix and source) - Sleek/noble design (black/gold, serif typography) Also includes: - New stdlib/json.lux module for JSON serialization - Enhanced stdlib/http.lux with middleware and routing - New string functions (charAt, indexOf, lastIndexOf, repeat) - LSP improvements (rename, signature help, formatting) - Package manager transitive dependency resolution - Updated documentation for effects and stdlib - New showcase example (task_manager.lux) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
176 lines
6.7 KiB
HTML
176 lines
6.7 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>Documentation - Lux</title>
|
|
<meta name="description" content="Lux language documentation and API reference.">
|
|
<link rel="icon" href="data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'><text y='.9em' font-size='90'>✨</text></svg>">
|
|
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
<link href="https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;600&family=Playfair+Display:wght@400;600;700&family=Source+Serif+4:opsz,wght@8..60,400;8..60,500;8..60,600&display=swap" rel="stylesheet">
|
|
<link rel="stylesheet" href="../static/style.css">
|
|
<style>
|
|
.docs-container {
|
|
max-width: 1000px;
|
|
margin: 0 auto;
|
|
padding: var(--space-xl) var(--space-lg);
|
|
}
|
|
|
|
.docs-header {
|
|
text-align: center;
|
|
margin-bottom: var(--space-2xl);
|
|
}
|
|
|
|
.docs-header p {
|
|
font-size: 1.1rem;
|
|
}
|
|
|
|
.docs-sections {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
|
|
gap: var(--space-lg);
|
|
}
|
|
|
|
.docs-section {
|
|
background: var(--bg-glass);
|
|
border: 1px solid var(--border-subtle);
|
|
border-radius: 8px;
|
|
padding: var(--space-lg);
|
|
}
|
|
|
|
.docs-section h2 {
|
|
font-size: 1.25rem;
|
|
margin-bottom: var(--space-md);
|
|
text-align: left;
|
|
}
|
|
|
|
.docs-section ul {
|
|
list-style: none;
|
|
}
|
|
|
|
.docs-section li {
|
|
margin-bottom: var(--space-sm);
|
|
}
|
|
|
|
.docs-section a {
|
|
display: block;
|
|
color: var(--text-secondary);
|
|
padding: var(--space-xs) 0;
|
|
transition: color 0.2s ease;
|
|
}
|
|
|
|
.docs-section a:hover {
|
|
color: var(--gold);
|
|
}
|
|
|
|
.docs-section p {
|
|
font-size: 0.95rem;
|
|
color: var(--text-muted);
|
|
margin-bottom: var(--space-md);
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<nav>
|
|
<a href="/" class="logo">Lux</a>
|
|
<ul class="nav-links" id="nav-links">
|
|
<li><a href="/install">Install</a></li>
|
|
<li><a href="/tour/">Tour</a></li>
|
|
<li><a href="/examples/">Examples</a></li>
|
|
<li><a href="/docs/" class="active">Docs</a></li>
|
|
<li><a href="/play">Play</a></li>
|
|
<li><a href="https://git.qrty.ink/blu/lux" class="nav-source">Source</a></li>
|
|
</ul>
|
|
</nav>
|
|
|
|
<main class="docs-container">
|
|
<header class="docs-header">
|
|
<h1>Documentation</h1>
|
|
<p>Complete reference for the Lux programming language.</p>
|
|
</header>
|
|
|
|
<div class="docs-sections">
|
|
<div class="docs-section">
|
|
<h2>Standard Library</h2>
|
|
<p>Core types and functions.</p>
|
|
<ul>
|
|
<li><a href="stdlib/list.html">List</a></li>
|
|
<li><a href="stdlib/string.html">String</a></li>
|
|
<li><a href="stdlib/option.html">Option</a></li>
|
|
<li><a href="stdlib/result.html">Result</a></li>
|
|
<li><a href="stdlib/math.html">Math</a></li>
|
|
<li><a href="stdlib/json.html">Json</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="docs-section">
|
|
<h2>Effects</h2>
|
|
<p>Built-in effect types and operations.</p>
|
|
<ul>
|
|
<li><a href="effects/console.html">Console</a></li>
|
|
<li><a href="effects/file.html">File</a></li>
|
|
<li><a href="effects/process.html">Process</a></li>
|
|
<li><a href="effects/http.html">Http</a></li>
|
|
<li><a href="effects/http-server.html">HttpServer</a></li>
|
|
<li><a href="effects/time.html">Time</a></li>
|
|
<li><a href="effects/random.html">Random</a></li>
|
|
<li><a href="effects/state.html">State</a></li>
|
|
<li><a href="effects/fail.html">Fail</a></li>
|
|
<li><a href="effects/sql.html">Sql</a></li>
|
|
<li><a href="effects/postgres.html">Postgres</a></li>
|
|
<li><a href="effects/concurrent.html">Concurrent</a></li>
|
|
<li><a href="effects/channel.html">Channel</a></li>
|
|
<li><a href="effects/test.html">Test</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="docs-section">
|
|
<h2>Language Reference</h2>
|
|
<p>Syntax, types, and semantics.</p>
|
|
<ul>
|
|
<li><a href="spec/grammar.html">Grammar (EBNF)</a></li>
|
|
<li><a href="spec/types.html">Type System</a></li>
|
|
<li><a href="spec/effects.html">Effect System</a></li>
|
|
<li><a href="spec/operators.html">Operators</a></li>
|
|
<li><a href="spec/keywords.html">Keywords</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="docs-section">
|
|
<h2>Guides</h2>
|
|
<p>In-depth explanations of key concepts.</p>
|
|
<ul>
|
|
<li><a href="../learn/effects.html">Effects Guide</a></li>
|
|
<li><a href="../learn/behavioral-types.html">Behavioral Types</a></li>
|
|
<li><a href="../learn/compilation.html">Compilation</a></li>
|
|
<li><a href="../learn/performance.html">Performance</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="docs-section">
|
|
<h2>Coming From</h2>
|
|
<p>Lux for developers of other languages.</p>
|
|
<ul>
|
|
<li><a href="../learn/from-rust.html">Rust</a></li>
|
|
<li><a href="../learn/from-haskell.html">Haskell</a></li>
|
|
<li><a href="../learn/from-typescript.html">TypeScript</a></li>
|
|
<li><a href="../learn/from-python.html">Python</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="docs-section">
|
|
<h2>Tooling</h2>
|
|
<p>CLI, LSP, and editor integration.</p>
|
|
<ul>
|
|
<li><a href="tools/cli.html">CLI Reference</a></li>
|
|
<li><a href="tools/lsp.html">LSP Setup</a></li>
|
|
<li><a href="tools/vscode.html">VS Code</a></li>
|
|
<li><a href="tools/neovim.html">Neovim</a></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
</main>
|
|
</body>
|
|
</html>
|