{"id":19356896,"url":"https://github.com/alexfigliolia/frame-pooler","last_synced_at":"2026-02-14T12:01:57.141Z","repository":{"id":247309668,"uuid":"825509338","full_name":"alexfigliolia/frame-pooler","owner":"alexfigliolia","description":"A task manager for distributing callbacks between animation frames","archived":false,"fork":false,"pushed_at":"2025-01-13T19:09:26.000Z","size":146,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-23T10:46:42.661Z","etag":null,"topics":["animation","scheduling","task-manager","typescript"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/@figliolia/frame-pooler","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/alexfigliolia.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2024-07-08T01:10:12.000Z","updated_at":"2025-01-13T19:09:30.000Z","dependencies_parsed_at":"2024-07-08T02:29:32.072Z","dependency_job_id":"76392c78-4bcc-4808-aa92-a333daaee47b","html_url":"https://github.com/alexfigliolia/frame-pooler","commit_stats":null,"previous_names":["alexfigliolia/frame-pooler"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/alexfigliolia/frame-pooler","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexfigliolia%2Fframe-pooler","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexfigliolia%2Fframe-pooler/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexfigliolia%2Fframe-pooler/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexfigliolia%2Fframe-pooler/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alexfigliolia","download_url":"https://codeload.github.com/alexfigliolia/frame-pooler/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexfigliolia%2Fframe-pooler/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29443468,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-14T10:51:12.367Z","status":"ssl_error","status_checked_at":"2026-02-14T10:50:52.088Z","response_time":53,"last_error":"SSL_read: 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":["animation","scheduling","task-manager","typescript"],"created_at":"2024-11-10T07:05:46.874Z","updated_at":"2026-02-14T12:01:57.124Z","avatar_url":"https://github.com/alexfigliolia.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Frame Pooler\nA task queue for distributing callbacks into animation frames. The Frame Pooler will allow you to run sequential tasks and automatically handle task distribution based on a maximum frame-duration and callstack size.\n\nThis library is primarily designed for heavy DOM manipulation and/or animation.\n\n## Installation\n```bash\nnpm i @figliolia/frame-pooler\n# or\nyarn add @figliolia/frame-pooler\n```\n\n## Basic Usage\n```typescript\nimport { FramePooler } from \"@figliolia/frame-pooler\";\n\nconst Pooler = new FramePooler(\n  100 \n  /* max call stack size per frame (defaults to Infinity) */\n);\n\nPooler.run((time: number) =\u003e {\n  // heavy DOM reads or updates\n});\n```\n\n### Background\nWhen building an animation-intensive JavaScript library I found myself benchmarking the performance of concurrent calls to `requestAnimationFrame` vs. pooling callbacks into already open animation frames. \n\nDue to the fact that logic executed inside of `requestAnimationFrame` can itself take any duration, I landed upon a game loop-like solution for my library - where an animation loop would remain running as long as tasks were pending. And if a given set of tasks exceeded a safe duration for a single frame, the frame will close with remaining tasks executing in the next available frame.\n\nThus allowing for the best possible frame rate the end-user's device could handle while still receiving user-input.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexfigliolia%2Fframe-pooler","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falexfigliolia%2Fframe-pooler","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexfigliolia%2Fframe-pooler/lists"}