{"id":45217018,"url":"https://github.com/flyingrobots/svjif","last_synced_at":"2026-02-20T17:13:11.966Z","repository":{"id":338957654,"uuid":"1159438838","full_name":"flyingrobots/svjif","owner":"flyingrobots","description":"SVJif - Scene Vector Jraphics interface format. Deterministic GPU scene IR for interactive vector UI.","archived":false,"fork":false,"pushed_at":"2026-02-17T11:01:41.000Z","size":139,"stargazers_count":0,"open_issues_count":7,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-02-17T14:09:15.450Z","etag":null,"topics":["compiler","dom","dom-renderer","dom-rendering","gpu","graphql","svjif","vector-graphics","webgl"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/flyingrobots.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-02-16T18:21:28.000Z","updated_at":"2026-02-17T11:01:45.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/flyingrobots/svjif","commit_stats":null,"previous_names":["flyingrobots/svjif"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/flyingrobots/svjif","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flyingrobots%2Fsvjif","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flyingrobots%2Fsvjif/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flyingrobots%2Fsvjif/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flyingrobots%2Fsvjif/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/flyingrobots","download_url":"https://codeload.github.com/flyingrobots/svjif/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flyingrobots%2Fsvjif/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29658176,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-20T16:33:43.953Z","status":"ssl_error","status_checked_at":"2026-02-20T16:33:43.598Z","response_time":59,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["compiler","dom","dom-renderer","dom-rendering","gpu","graphql","svjif","vector-graphics","webgl"],"created_at":"2026-02-20T17:13:11.859Z","updated_at":"2026-02-20T17:13:11.959Z","avatar_url":"https://github.com/flyingrobots.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SVJif\n\n**Scene Vector Jraphics interface format**\n\nPronounced: **\"Scene Vector Jif\"** (/siːn ˈvɛktər dʒɪf/)\n\nDeterministic GPU scene IR for interactive vector UI.\n\n\u003e Unlike legacy SVG weirdness, SVJif uses a sane Euclidean coordinate space:\n\u003e - explicit origin\n\u003e - explicit units\n\u003e - explicit transforms\n\u003e - deterministic layout + draw\n\n## Status: v0.1.0-dev 🚧\n\n**Compiler architecture complete.** Now implementing:\n- GraphQL → Canonical AST parser\n- Semantic validation\n- Full artifact emission\n\n## What is SVJif?\n\nSVJif is the **canonical intermediate representation** for GPU-native vector UI rendering. It's not a replacement for SVG or the browser DOM—it's the universal compile target for high-performance GPU rendering.\n\n**Think LLVM IR, but for UI.**\n\n## What is GPVue?\n\n**GPVue** is the developer-facing Vue SDK that compiles Vue components to SVJif for deterministic GPU rendering.\n\n**Positioning:** GPVue compiles Vue components to SVJif for deterministic GPU rendering.\n\nAt runtime: no CSS parser, no cascade—only deterministic subtree relayout and GPU draw.\n\n## Architecture\n\n```\nGPVue / GPReact / GPSvelte / GPFigma\n              ↓\n       SVJif IR (universal format)\n              ↓\n    ┌─────────┼─────────┬─────────┬─────────┐\n    ↓         ↓         ↓         ↓         ↓\n  WebGL    WebGPU     Metal    Vulkan     wgpu\n (browser) (browser)  (Apple)  (native)   (Rust)\n```\n\n**SVJif is the compile target. Renderers are swappable.**\n\nLike LLVM IR → multiple backends, or WASM → multiple runtimes.\n\n## Architecture\n\n```\nVue/Figma/SVG\n       ↓\n  SVJif Compiler (build time)\n       ↓\n   SVJif IR (.svjif.json)\n       ↓\n   Pack (.svjif.bin)\n       ↓\n  WebGL Runtime (GPU rendering)\n```\n\n## Key Principles\n\n1. **Deterministic** - Same IR in, same pixels out\n2. **Build-time CSS** - No runtime parsing or cascade\n3. **Runtime layout VM** - Only recompute dirty subtrees\n4. **GPU-native** - Direct shader rendering\n5. **Fail loud** - Unsupported features are compile errors\n\n## Project Status\n\n🚧 **v0.1 in development** - Terminal rendering proof of concept\n\n## Repository Structure\n\n```\nSVJif/\n  packages/\n    # SVJif Core (universal IR)\n    core/              # @svjif/core - IR types, validation\n    compiler/          # @svjif/compiler - Base compiler infra\n    cli/               # @svjif/cli - Command-line tools\n\n    # SVJif Runtimes (swappable backends)\n    runtime-webgl/     # @svjif/runtime-webgl - WebGL (browser)\n    runtime-webgpu/    # @svjif/runtime-webgpu - WebGPU (modern browser)\n    runtime-metal/     # @svjif/runtime-metal - Metal (Apple native)\n    runtime-wgpu/      # @svjif/runtime-wgpu - wgpu (Rust)\n    runtime-vulkan/    # @svjif/runtime-vulkan - Vulkan (cross-platform)\n\n    # Front-end SDKs (compile to SVJif)\n    gpvue/             # @gpvue/vue - Vue → SVJif\n    gpreact/           # @gpreact/react - React → SVJif (future)\n    gpsvelte/          # @gpsvelte/svelte - Svelte → SVJif (future)\n\n  schemas/\n    svjif.v0.1.json    # SVJif IR JSON Schema\n  examples/\n    gpvue-terminal/    # GPVue cloth terminal demo\n  docs/\n    spec.md            # SVJif specification\n    runtime-api.md     # Runtime interface contract\n```\n\n## Runtime Abstraction\n\nAll SVJif runtimes implement the same interface:\n\n```typescript\ninterface SVJifRuntime {\n  load(scene: SVJifScene): Promise\u003cvoid\u003e;\n  render(): void;\n  updateNode(id: string, updates: Partial\u003cSVJifNode\u003e): void;\n  hitTest(x: number, y: number): HitResult | null;\n  dispose(): void;\n}\n```\n\n**Same IR. Same API. Different GPU backend.**\n\nChoose your runtime:\n- **Browser?** → `@svjif/runtime-webgl` or `@svjif/runtime-webgpu`\n- **Native app?** → `@svjif/runtime-metal` (macOS/iOS) or `@svjif/runtime-vulkan`\n- **Rust?** → `@svjif/runtime-wgpu`\n\n## Supported CSS Subset (v0.1)\n\n**Layout:** `display`, `flex-*`, `width`, `height`, `padding`, `margin`, `gap`, `position`\n**Paint:** `background-color`, `color`, `border`, `border-radius`, `opacity`\n**Text:** `font-family`, `font-size`, `font-weight`, `line-height`, `text-align`\n\nSee [docs/css-subset.md](docs/css-subset.md) for full details.\n\n## Quick Start (coming soon)\n\n### For Vue Developers (GPVue)\n\n```bash\n# Install GPVue\nnpm install @gpvue/vue\n\n# Write your Vue component\n# Terminal.vue - renders on GPU!\n\n# Build to SVJif\nnpx gpvue build Terminal.vue\n\n# Run\nnpx gpvue serve --gpu\n```\n\n### For Format/Tooling Developers (SVJif Core)\n\n```bash\n# Install SVJif tools\nnpm install -g @svjif/cli\n\n# Validate SVJif IR\nsvjif validate terminal.svjif.json\n\n# Pack for production\nsvjif pack terminal.svjif.json -o terminal.svjif.bin\n\n# Build your own compiler targeting SVJif\nimport { SVJifScene } from '@svjif/core';\n```\n\n## Development Principles\n\n- **Apache 2.0 License** - Open and permissive\n- **Hexagonal Architecture** - Domain/Application/Infrastructure layers\n- **TypeScript** - Strict mode, full type safety\n- **H-H-H-HOLY SHIT ESLint** - Maximum strictness (eslint:all + @typescript-eslint/all)\n- **Test is the Spec** - Tests define behavior, 90%+ coverage required\n\n## Project Structure\n\n```\n@svjif/core\n  src/\n    domain/          # Pure domain logic (models, business rules)\n      models/        # SVJifNode, SVJifScene types\n      ports/         # Interfaces for external dependencies\n    application/     # Use cases and application services\n      usecases/      # Business workflows\n      services/      # Application logic\n    infrastructure/  # External adapters (I/O, frameworks)\n      adapters/      # Concrete implementations\n```\n\n## License\n\nApache 2.0\n\n## Contributing\n\nSVJif is in early development. Watch this space.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflyingrobots%2Fsvjif","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fflyingrobots%2Fsvjif","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflyingrobots%2Fsvjif/lists"}