LunarWerxs/AnatomyOf
LunarWerxs/AnatomyOf has 29 GitHub stars and 5 forks. GitHot measured 0 stars in 24 hours and 0 in 7 days. Last checked 2026-11-17 01:47 UTC. Last push 2026-11-10.
What you can do
- 🔬 Dozens of languages, plus concept pages: from Python and Rust to Ada, Prolog, COBOL, GML, and WebAssembly
- 🎨 Color-coded callouts wired to the exact lines they describe
- 🖱️ Hover to trace, click to dive: a full deep-dive modal per concept, with a Learn more link
- 🌗 Light & dark themes, and fully mobile-responsive (tap to pin a callout, tap again to open it)
Measured star growth
- in 24h
- 0
- in 7 days
- 0
- in 15 days
- Collecting history
- in 1 month
- Collecting history
Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.
About
Interactive 'Anatomy of a File' explorer - annotated tours of source files, language by language
Developer ToolsREADME.md
OriginalAnatomyOf is a free, open-source web app that teaches programming language syntax through interactively annotated source-code examples, pairing minimal and verbose code samples with hover-and-click callouts that explain each structural part (imports, control flow, class definitions) for dozens of languages, plus non-code concept pages like a website or a CI pipeline.
AnatomyOf opens an example source file in a code
window with color-coded callouts explaining every structural part: shebang, imports, class
definitions, control flow, and more. Hover a callout to trace it into the code; click
it for an in-depth writeup. Every language ships a minimal and a verbose example
(switching between them morphs the code: lines the two share slide to their new place and
only the differing lines fade in or out), light & dark themes, and shareable URLs like
/#/python/verbose.
Beyond real languages, concept pages dissect the structural anatomy of a website, a settings screen, a mobile app, a dashboard, an email, a CI pipeline, and a GitHub contribution: the same idea, applied to things that aren't code.
✨ Highlights
- 🔬 Dozens of languages, plus concept pages: from Python and Rust to Ada, Prolog, COBOL, GML, and WebAssembly
- 🎨 Color-coded callouts wired to the exact lines they describe
- 🖱️ Hover to trace, click to dive: a full deep-dive modal per concept, with a Learn more link
- 🌗 Light & dark themes, and fully mobile-responsive (tap to pin a callout, tap again to open it)
- 🧭 Sidebar ranked by real-world popularity (TIOBE Index), toggleable to A-Z, with instant search
- ⚡ Syntax highlighting by Shiki. The same engine VS Code uses
- 🔗 Deep-linkable URLs for every language and variant
- 🥚 A few easter eggs hiding behind the code window's traffic-light buttons
🚀 Live
→ anatomyof.lunarwerx.com
🛠️ Built with
Bun · Vite · Vue 3 · TypeScript · Tailwind CSS 4 · Reka UI · Shiki · Biome
🧑💻 Quick start / Develop
cd app
bun install
bun run dev # http://localhost:5173
bun run build # type-check + production build
bun run check # biome lint/format + grammar/example checks
The live site is built and deployed by GitHub Actions in the companion
anatomyof.github.io repo, which builds
this repo's app/ on a schedule and on demand.
➕ Adding a language
Everything is data-driven, one file per language in app/src/data/:
Create
app/src/data/<id>.tsexporting aLanguageDef: metadata, an annotation catalog (card text + modal deep-dive), and two example variants built from segments ({ code, refs }). Line ranges are derived automatically, never hand-counted. For a non-language "concept" page, setcategory: 'concept'andtitleNoun: ''.Humor is part of the spec. Every example must carry a little tasteful, language-specific coding humor: comical, ironic, or a nerdy in-joke/quote a dev of that language would appreciate (Zen of Python, Rust's borrow checker, Perl's write-only reputation, …). Put it only in comments and string/print literals, keep the code valid and still clearly teaching, and never rename an identifier that an annotation references. 2-5 touches per language.
Add the grammar import to
app/src/lib/highlighter.ts(enforced byapp/scripts/check-grammars.ts, which runs inbun run build/check).Set a
popularityrank on theLanguageDefand remove it fromcomingSoon.tsif applicable. Runbun run gen:catalog(also run automatically bybun run build) to regenerate the catalog and lazy-loader map. The sidebar's Languages group is sorted bypopularity(TIOBE Index position; lower = higher up, with a documented convention for entries TIOBE can't rank). Concepts omitpopularityand keep their curated order.
Brand assets (favicon, social card, in-app mark) are all generated from
app/public/logo.svgviabun run scripts/gen-brand.ts.
🖼️ Adding a Visual variant
Entries can carry a third toggle option next to minimal and verbose, showing
diagrams instead of code. The button appears only for entries that define a visual
block, so nothing needs to be greyed out anywhere else.
Diagrams are data, never hand-drawn SVG. Each panel names one of the reusable
templates in app/src/lib/visual.ts, which computes the geometry; the components under
app/src/components/visual/ only draw what it returns. Adding a diagram to a new entry
is therefore a data edit, and a template gets reused by describing content rather than
redrawing it.
| Template | Shape | Answers |
|---|---|---|
topology |
Boxes in dashed zones, labelled arrows | What lives where, and what moves it |
graph |
Lanes with branch/merge curves | In what order |
timeline |
Bars on a clock | What overlapped, and what waited |
Every element carries a ref naming the annotation it belongs to, exactly like a code
segment's refs, so hover, callout cards, and connector lines work unchanged. One page
may stack several panels, and an annotation referenced by two of them highlights in both
at once. See ci.ts (topology + timeline) and github.ts (topology + graph).
An annotation may be referenced only by a diagram, in which case it appears on the
Visual tab and nowhere else. That is how javascript.ts documents the event loop without
inventing async code for its examples: the call stack and the two queues are runtime
facts, not syntax. app/scripts/check-examples.ts enforces both directions, that every
diagram ref resolves to a real annotation, and that no annotation is orphaned.
topologysuits things with a client/server split and does not generalize to a single source file;graphandtimelinedo, so they are the ones to reach for if the Visual tab ever grows past the concept pages.
The maintainers' visual-variants design notes (kept privately) record the reasoning: which entries earn a diagram and which do not, what was tried and rejected, the remaining candidates with what each would cost, and the gotchas worth knowing before touching it.
🔒 Privacy
On page load the site sends one anonymous visit ping to LunarWerx's own endpoint
(studio.connections.icu): a random visitor id kept in localStorage. Server-side it
becomes a daily-uniques count (with coarse country) that expires after 90 days.
AnatomyOf collects anonymous usage statistics (such as page views, the version in use and which features are used) to see what people use and improve it.
🆚 How it compares
AnatomyOf sits closest to Learn X in Y Minutes, a free, open-source, community-maintained catalog of language, framework, and tool overviews under a CC BY-SA license, hosted on GitHub and open to pull requests. Both are free tours across many languages with no account required. The formats differ: Learn X in Y Minutes presents each language as a single commented code file, read top to bottom like an article. AnatomyOf instead renders a code window with clickable, color-coded callouts tied to exact lines, a separate deep-dive modal per concept, minimal and verbose variants, and light/dark themes, and it extends that same annotated-tour format to non-code concepts (a CI pipeline, a GitHub contribution) that a syntax-focused catalog doesn't cover. Compared with a language's own official docs or tutorial, AnatomyOf is narrower in depth (it is not a full reference) but consistent in presentation across every language it covers.
❓ FAQ
Is AnatomyOf free? Yes. AnatomyOf is free and open source under the MIT License, with the full source on GitHub. There is no account, sign-up, or paid tier: opening the site is the entire onboarding, and anyone can fork or self-host it under the same license.
Does it work offline?
No. AnatomyOf is a client-side web app deployed to GitHub Pages with no service worker or
offline mode built in, so it needs an internet connection to load. You can run a local copy
with bun install and bun run dev (see Quick start, above) and use it on your own network
instead.
What are the system requirements? None beyond a reasonably current desktop or mobile browser. AnatomyOf is a static Vue 3 single-page app with no installer, account, or backend to configure; the layout is fully mobile-responsive, so a phone or tablet works as well as a laptop.
How is it different from Learn X in Y Minutes? Both are free tours across many languages, but the format differs. Learn X in Y Minutes presents each language as a single commented code file read top to bottom; AnatomyOf renders a code window with clickable, color-coded callouts, a separate deep-dive modal per concept, minimal and verbose variants, and light/dark themes.
Is my data sent anywhere? On page load AnatomyOf sends one anonymous visit ping (a random visitor id in localStorage, plus a coarse country) to LunarWerx's own endpoint. It expires after 90 days.
Which languages does it cover? Dozens, from mainstream ones like Python, Rust, and TypeScript to less common picks such as Ada, Prolog, COBOL, GML, and WebAssembly, each ranked in the sidebar by real-world popularity via the TIOBE Index (toggleable to A-Z). Concept pages extend the same format to things that aren't code, like a CI pipeline or a GitHub contribution.
Can I add a language myself?
Yes. AnatomyOf is data-driven: adding a language means creating one LanguageDef file under
app/src/data/, with minimal and verbose code examples plus an annotation catalog, then
adding its grammar to the highlighter. See "Adding a language," above, for the full steps.
📄 License
MIT © LunarWerx: free to use, fork, and adapt.
Built by LunarWerx · Deployed on GitHub Pages
Made by LunarWerx Studios. Also check out RepoYeti, DevWebUI, and QuickDictate.