{"id":15408922,"url":"https://github.com/sec-ant/xielder","last_synced_at":"2026-01-31T19:34:12.559Z","repository":{"id":183937762,"uuid":"671044025","full_name":"Sec-ant/xielder","owner":"Sec-ant","description":"A yield expression is only allowed in a generator body. But you can xield anywhere.","archived":false,"fork":false,"pushed_at":"2025-08-05T02:39:26.000Z","size":263,"stargazers_count":0,"open_issues_count":2,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-19T00:21:29.323Z","etag":null,"topics":["xield","xielder","yield"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/xielder/v/latest","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/Sec-ant.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}},"created_at":"2023-07-26T12:15:06.000Z","updated_at":"2023-09-15T08:39:43.000Z","dependencies_parsed_at":"2024-04-23T05:49:04.244Z","dependency_job_id":"2000e663-a0c8-4c39-8105-55dd8fc72540","html_url":"https://github.com/Sec-ant/xielder","commit_stats":{"total_commits":40,"total_committers":3,"mean_commits":"13.333333333333334","dds":0.25,"last_synced_commit":"72581bbe2903977361cdd3a4d6a9d59f8097f062"},"previous_names":["sec-ant/xielder"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/Sec-ant/xielder","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sec-ant%2Fxielder","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sec-ant%2Fxielder/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sec-ant%2Fxielder/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sec-ant%2Fxielder/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Sec-ant","download_url":"https://codeload.github.com/Sec-ant/xielder/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Sec-ant%2Fxielder/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28951442,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-31T18:30:42.805Z","status":"ssl_error","status_checked_at":"2026-01-31T18:30:19.593Z","response_time":128,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6: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":["xield","xielder","yield"],"created_at":"2024-10-01T16:35:59.205Z","updated_at":"2026-01-31T19:34:12.543Z","avatar_url":"https://github.com/Sec-ant.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# xielder\n\n\u003e A `yield` expression is only allowed in a generator body. --`ts(1163)`\n\nBut you can **`xield`** anywhere.\n\n## Install\n\n```bash\nnpm i xielder\n```\n\n## Usage\n\n❌ You can not `yield` in a callback function:\n\n```ts\nfunction* x() {\n  setInterval(() =\u003e {\n    yield Date.now();\n  }, 1000);\n}\n\nfor (const d of x) {\n  console.log(d);\n}\n```\n\n✅ But you can `xield` in it:\n\n```ts\nimport { xielder } from \"xielder\";\n\nconst x = xielder\u003cnumber\u003e((xield) =\u003e {\n  setInterval(() =\u003e {\n    xield(Date.now());\n  }, 1000);\n});\n\nfor await (const d of x) {\n  console.log(d);\n}\n```\n\n✅ use `close` to stop `xield`ing:\n\n```ts\nimport { xielder } from \"xielder\";\n\nconst x = xielder\u003cnumber\u003e((xield, close) =\u003e {\n  setInterval(() =\u003e {\n    xield(Date.now());\n  }, 1000);\n\n  setTimeout(() =\u003e {\n    close();\n  }, 15000);\n});\n\nfor await (const d of x) {\n  console.log(d);\n}\n```\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsec-ant%2Fxielder","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsec-ant%2Fxielder","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsec-ant%2Fxielder/lists"}