{"id":13998496,"url":"https://github.com/trycatch-labs/dark","last_synced_at":"2026-03-17T20:02:40.474Z","repository":{"id":39359196,"uuid":"212950339","full_name":"trycatch-labs/dark","owner":"trycatch-labs","description":"The lightweight and powerful UI rendering engine without dependencies and written in TypeScript💫 (Browser, Node.js, Android, iOS, Windows, Linux, macOS)","archived":false,"fork":false,"pushed_at":"2025-10-10T16:46:31.000Z","size":52141,"stargazers_count":51,"open_issues_count":7,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-02-15T14:52:42.944Z","etag":null,"topics":["angular","components","concurrent","fiber","framework","frontend","hooks","jsx","nativescript","no-build-required","nodegui","performance","react","renderer","server-side-rendering","spring-animation","typescript","ui","virtual-dom","web"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/trycatch-labs.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2019-10-05T05:42:49.000Z","updated_at":"2025-12-06T09:37:15.000Z","dependencies_parsed_at":"2023-10-14T16:48:19.050Z","dependency_job_id":"3e00f3bf-66fa-40fa-8507-fe970bc2b46d","html_url":"https://github.com/trycatch-labs/dark","commit_stats":{"total_commits":1780,"total_committers":3,"mean_commits":593.3333333333334,"dds":0.008988764044943864,"last_synced_commit":"5dcdc4124565f0ebbd87f7cf7ff24a157dfb01ce"},"previous_names":[],"tags_count":96,"template":false,"template_full_name":null,"purl":"pkg:github/trycatch-labs/dark","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trycatch-labs%2Fdark","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trycatch-labs%2Fdark/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trycatch-labs%2Fdark/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trycatch-labs%2Fdark/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/trycatch-labs","download_url":"https://codeload.github.com/trycatch-labs/dark/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/trycatch-labs%2Fdark/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30464987,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-13T06:34:02.089Z","status":"ssl_error","status_checked_at":"2026-03-13T06:33:49.182Z","response_time":60,"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":["angular","components","concurrent","fiber","framework","frontend","hooks","jsx","nativescript","no-build-required","nodegui","performance","react","renderer","server-side-rendering","spring-animation","typescript","ui","virtual-dom","web"],"created_at":"2024-08-09T19:01:43.372Z","updated_at":"2026-03-17T20:02:39.022Z","avatar_url":"https://github.com/trycatch-labs.png","language":"TypeScript","readme":"\u003cdiv align=\"center\"\u003e\n\u003ch1\u003eDark\u003c/h1\u003e\n\nThe lightweight and powerful UI rendering engine without dependencies and written in TypeScript \u003cbr\u003e (Browser, Node.js, Android, iOS, Windows, Linux, macOS)\n\n\u003cimg alt=\"license\" src=\"https://img.shields.io/github/license/atellmer/dark?style=flat\u0026colorA=000063\u0026colorB=673ab7\"\u003e\n\u003cimg alt=\"github release\" src=\"https://img.shields.io/github/release/atellmer/dark.svg?style=flat\u0026colorA=000063\u0026colorB=673ab7\"\u003e\n\u003cimg alt=\"npm downloads\" src=\"https://img.shields.io/npm/dt/%40dark-engine%2Fcore.svg?style=flat\u0026colorA=000063\u0026colorB=673ab7\"\u003e\n\u003cimg alt=\"bundle size\" src=\"https://img.shields.io/bundlejs/size/%40dark-engine%2Fcore?label=size%20(gzip)\u0026style=flat\u0026colorA=000063\u0026colorB=673ab7\"\u003e\n\u003cimg alt=\"tests\" src=\"https://github.com/atellmer/dark/actions/workflows/test.yml/badge.svg\"\u003e\n\n\u003c/div\u003e\n\n\u003cdiv align=\"center\"\u003e \n  \u003cimg src=\"./assets/cover.jpg\"\u003e\n\u003c/div\u003e\n\n## Features\n- 🌟 Reactive\n- 🎉 Declarative\n- 🛸 Fast\n- 🏭 Has components and hooks\n- 🧶 Based on the Fiber architecture\n- ⚡️ Сan use without build tools\n- 🦾 Strongly typed\n- 🦄 Small size (4x smaller than React)\n- ✂️ No dependencies\n- 💥 Tree-shakeable\n- 🔄 Async rendering\n- 🔀 Concurrent rendering\n- 🥱 Lazy loading modules\n- 🎀 Suspense fallbacks\n- 🧲 Error boundaries\n- ☄️ Hot module replacement\n- 🔔 Signals\n- 💅 Styled components\n- 💃🏼 Spring animations\n- 💽 Server-side rendering\n- 🏄‍♂️ Isomorphic routing\n- 📖 SEO metadata\n- 💾 Shared state between server and client\n- 🧿 Server asynchronous code in the app (in SSR)\n- 📬 Declarative queries and mutations\n- 📲 Rendering to mobile platforms (Android, iOS) via \u003ca href=\"https://nativescript.org/\" target=\"_blank\"\u003eNativeScript\u003c/a\u003e\n- 💻 Rendering to desktop platforms (Windows, Linux, macOS) via \u003ca href=\"https://docs.nodegui.org/\" target=\"_blank\"\u003eNodeGui\u003c/a\u003e\n- ⚙️ Over 500 unit and integration tests passed\n\n```tsx\nconst Greeting = component(({ name }) =\u003e \u003ch1\u003eHello {name} 🥰\u003c/h1\u003e);\n\n\u003cGreeting name='Alice' /\u003e\n```\n\n## Installation\n\nfrom template:\n```\nnpx degit github:trycatch-labs/dark/templates/browser app\n```\n\n```\ncd app\nnpm i\nnpm start\n```\n\n## Dark vs React Fiber\n\n- [Concurrent Sierpinski triangle](https://trycatch-labs.github.io/dark/next/sierpinski-triangle/)\n\n## Demos\n\n- [1k components](https://trycatch-labs.github.io/dark/next/1k-components/)\n- [10k rows](https://trycatch-labs.github.io/dark/next/10k-rows/)\n- [Animated grid](https://trycatch-labs.github.io/dark/next/animated-grid/)\n- [Concurrent deferred search](https://trycatch-labs.github.io/dark/next/deferred-search/)\n- [Spring draggable list](https://trycatch-labs.github.io/dark/next/spring-draggable-list/)\n- [Spring snake](https://trycatch-labs.github.io/dark/next/spring-snake/)\n- [Spring masonry grid](https://trycatch-labs.github.io/dark/next/spring-masonry-grid/)\n- [Spring slider](https://trycatch-labs.github.io/dark/next/spring-slider/)\n- [Spring menu](https://trycatch-labs.github.io/dark/next/spring-menu/)\n- [Spring dialog window](https://trycatch-labs.github.io/dark/next/spring-dialog/)\n\n## Stackblitz demos\n\n- [Dark context](https://stackblitz.com/edit/darkapp-ccz57rk-z41sup?file=index.tsx)\n- [Working with standard HTML input elements](https://stackblitz.com/edit/darkapp-ccz57rk-wqitdr?file=index.tsx)\n- [SPA with lazy routes](https://stackblitz.com/edit/darkapp-ccz57rk-hu65rp?file=index.tsx)\n- [Concurrent tabs](https://stackblitz.com/edit/darkapp-ccz57rk-g8ppbn?file=index.tsx)\n- [Spring page transitions](https://stackblitz.com/edit/darkapp-ccz57rk-ccf2wq?file=page-transition.tsx)\n- [Concurrent router](https://stackblitz.com/edit/darkapp-ccz57rk-fy8rha?file=index.tsx,pending.tsx)\n- [SSR+PWA app](https://stackblitz.com/edit/darkapp-ccz57rk-wrfqdk?file=backend%2Fapp.ts,frontend%2Fcomponents%2Fapp.tsx)\n\n## Motivation\n\nThis project was written in my free time as a hobby. I challenged myself: can I write something similar to React without third-party dependencies and alone. The biggest discovery for me: writing a rendering library is not difficult, it is difficult to write one that is fast and consumes little memory. And this is a really hard task.\n\n## Inspiration\n\nIf you liked the project, please rate it with a star ⭐, it gives me inspiration to work for the benefit of the open-source community.\n\n## Ecosystem\n\n| Package                          | Description                                                      | URL                                      |\n|----------------------------------|------------------------------------------------------------------|------------------------------------------|\n| `@dark-engine/core`              | Abstract core with main functionality                            | [Link](https://github.com/trycatch-labs/dark/tree/master/packages/core)             |\n| `@dark-engine/platform-browser`  | Renderer for browser (Single-Page apps)                          | [Link](https://github.com/trycatch-labs/dark/tree/master/packages/platform-browser) |\n| `@dark-engine/platform-server`   | Renderer for Node.js (Multi-Page, Static-Gen and Universal apps) | [Link](https://github.com/trycatch-labs/dark/tree/master/packages/platform-server)  |\n| `@dark-engine/platform-native`   | Renderer for Android, iOS (Native mobile apps)                   | [Link](https://github.com/trycatch-labs/dark/tree/master/packages/platform-native)  |\n| `@dark-engine/platform-desktop`  | Renderer for Windows, Linux, macOS (Native desktop apps)         | [Link](https://github.com/trycatch-labs/dark/tree/master/packages/platform-desktop) |\n| `@dark-engine/web-router`        | Isomorphic router for browser and server                         | [Link](https://github.com/trycatch-labs/dark/tree/master/packages/web-router)       |\n| `@dark-engine/native-navigation` | Dark NativeScript router                                         | [Link](https://github.com/trycatch-labs/dark/tree/master/packages/native-navigation)|\n| `@dark-engine/animations`        | Spring based animations                                          | [Link](https://github.com/trycatch-labs/dark/tree/master/packages/animations)       |\n| `@dark-engine/styled`            | Styled components                                                | [Link](https://github.com/trycatch-labs/dark/tree/master/packages/styled)           |\n| `@dark-engine/data`              | Declarative queries and mutations                                | [Link](https://github.com/trycatch-labs/dark/tree/master/packages/data)             |\n| `@dark-engine/signals`           | Signals, computed signals and signal effects                     | [Link](https://github.com/trycatch-labs/dark/tree/master/packages/signals)             |\n\n## Usage\n\n```tsx\nimport { component, useState } from '@dark-engine/core';\nimport { createRoot } from '@dark-engine/platform-browser';\n\nconst App = component(() =\u003e {\n  const [name, setName] = useState('Dark');\n\n  return (\n    \u003c\u003e\n      \u003cdiv\u003eHello {name}\u003c/div\u003e\n      \u003cinput value={name} onInput={e =\u003e setName(e.target.value)} /\u003e\n    \u003c/\u003e\n  );\n});\n\ncreateRoot(document.getElementById('root')).render(\u003cApp /\u003e);\n```\n\nwithout JSX:\n\n```tsx\nimport { Text, component, useState } from '@dark-engine/core';\nimport { createRoot, div, input } from '@dark-engine/platform-browser';\n\nconst App = component(() =\u003e {\n  const [name, setName] = useState('Dark');\n\n  return [\n    div({ slot: Text(`Hello ${name}`) }),\n    input({ value: name, onInput: e =\u003e setName(e.target.value) }),\n  ];\n});\n\ncreateRoot(document.getElementById('root')).render(App());\n```\n\n## Benchmark\n\n[js-framework-benchmark](https://krausest.github.io/js-framework-benchmark/2024/table_chrome_131.0.6778.85.html)\n\n\u003cimg src=\"./assets/bench.png\"\u003e\n\nBased on the benchmark results, Dark is approximately 28% slower than the reference `vanillajs-lite implementation`, yet it outperforms Angular, React and Preact.\n\n## Lighthouse\n\nA [small application](https://github.com/trycatch-labs/dark/tree/master/examples/server-side-rendering/) demonstrating the capabilities of Dark using `SSR`, `rendering to stream`, `service-worker`, `offline mode`, `concurrent rendering`, `caching`, `suspense`, `router`, `async queries`, `lazy` and `styled` components scores maximum points in Lighthouse.\n\n\u003cimg src=\"./assets/lighthouse.png\"\u003e\n\n## Concurrent feature\n\nDark can split large rendering tasks automatically.\n\n### Turn this...\n\n\u003cimg src=\"./assets/blocking.png\"\u003e\n\n### into this\n\n\u003cimg src=\"./assets/non-blocking.png\"\u003e\n\n# LICENSE\n\nMIT © [Alex Plex](https://github.com/atellmer)\n","funding_links":[],"categories":["TypeScript"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrycatch-labs%2Fdark","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftrycatch-labs%2Fdark","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftrycatch-labs%2Fdark/lists"}