{"id":19527361,"url":"https://github.com/daverandom/loopio","last_synced_at":"2025-10-25T08:05:58.948Z","repository":{"id":17790495,"uuid":"20667928","full_name":"DaveRandom/Loopio","owner":"DaveRandom","description":"Provides interoperability between Alert and React","archived":false,"fork":false,"pushed_at":"2014-07-22T16:09:24.000Z","size":296,"stargazers_count":6,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-22T02:41:38.738Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","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/DaveRandom.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}},"created_at":"2014-06-10T01:15:16.000Z","updated_at":"2016-01-12T18:56:26.000Z","dependencies_parsed_at":"2022-09-02T22:11:45.301Z","dependency_job_id":null,"html_url":"https://github.com/DaveRandom/Loopio","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/DaveRandom/Loopio","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DaveRandom%2FLoopio","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DaveRandom%2FLoopio/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DaveRandom%2FLoopio/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DaveRandom%2FLoopio/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DaveRandom","download_url":"https://codeload.github.com/DaveRandom/Loopio/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DaveRandom%2FLoopio/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":280923455,"owners_count":26414237,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-25T02:00:06.499Z","response_time":81,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":[],"created_at":"2024-11-11T01:14:43.819Z","updated_at":"2025-10-25T08:05:58.921Z","avatar_url":"https://github.com/DaveRandom.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"Loopio\n======\n\nProvides interoperability between [Alert](https://github.com/rdlowrey/Alert) and\n[React](https://github.com/reactphp/react).\n\nThis library is simply a set of adapters that will allow you to use applications designed around the React event loop to\nwork with an Alert event loop, and vice versa. It does not provide any complete functionality on its own.\n\nAdapters are provided for all stable versions of React up to the 0.4.x series, and all stable versions of Alert up to\nthe 0.8.x series, excluding the initial Alert release (0.1.0).\n\n###Installation\n\nPreferably via [Composer](https://getcomposer.org/).\n\n    \"require\": {\n        \"daverandom/loopio\": \"~0.1.0\"\n    }\n\n###Usage\n\nThe best way to create the correct adapter for the installed React and Alert versions is to use the appropriate method\nof `Loopio\\LoopFactory`. This will auto-detect the installed versions of Alert and React and return the correct adapter\nfor your combination.\n\n---\n\nIf you are using React as your primary event loop and you want to use a component designed around Alert in your\napplication (such as [Artax](https://github.com/rdlowrey/Artax)), an adapter can be created in the following manner:\n\n    \u003c?php\n\n    // Create a React event loop\n    $reactLoop = React\\EventLoop\\Factory::create();\n\n    // Create an Alert adapter\n    $alertLoop = (new Loopio\\LoopFactory)-\u003ecreateAlertLoop($reactLoop);\n\n    // Create an Artax async client\n    $client = new Artax\\AsyncClient($alertLoop);\n\n---\n\nIf you are using Alert as your primary event loop and you want to use a component designed around React in your\napplication (such as [Ratchet](https://github.com/ratchetphp/Ratchet)), an adapter can be created in the following\nmanner:\n\n    \u003c?php\n\n    // Create an Alert event loop\n    $alertLoop = (new Alert\\ReactorFactory)-\u003eselect();\n\n    // Create a React adapter\n    $reactLoop = (new Loopio\\LoopFactory)-\u003ecreateReactLoop($alertLoop);\n\n    // Create a Ratchet app\n    $client = new Ratchet\\App('localhost', 8080, '127.0.0.1', $reactLoop);\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdaverandom%2Floopio","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdaverandom%2Floopio","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdaverandom%2Floopio/lists"}