{"id":13484898,"url":"https://github.com/marpple/FxTS","last_synced_at":"2025-03-27T16:31:32.202Z","repository":{"id":38207820,"uuid":"411941706","full_name":"marpple/FxTS","owner":"marpple","description":"A functional programming library for TypeScript/JavaScript","archived":false,"fork":false,"pushed_at":"2024-04-14T04:32:20.000Z","size":7121,"stargazers_count":716,"open_issues_count":17,"forks_count":62,"subscribers_count":12,"default_branch":"main","last_synced_at":"2024-04-14T11:55:55.771Z","etag":null,"topics":["concurrency","fp","javascript","lazy","typescript"],"latest_commit_sha":null,"homepage":"https://fxts.dev","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/marpple.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":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2021-09-30T06:00:50.000Z","updated_at":"2024-04-25T02:37:29.950Z","dependencies_parsed_at":"2024-01-08T10:16:51.283Z","dependency_job_id":"bdaf21dd-cfd0-4ef1-9c1f-630339e83a9b","html_url":"https://github.com/marpple/FxTS","commit_stats":{"total_commits":384,"total_committers":20,"mean_commits":19.2,"dds":0.5911458333333333,"last_synced_commit":"856b178c370e8016d46b15b1ee10353d89c60076"},"previous_names":[],"tags_count":47,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marpple%2FFxTS","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marpple%2FFxTS/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marpple%2FFxTS/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marpple%2FFxTS/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/marpple","download_url":"https://codeload.github.com/marpple/FxTS/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245882433,"owners_count":20687888,"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","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":["concurrency","fp","javascript","lazy","typescript"],"created_at":"2024-07-31T17:01:38.102Z","updated_at":"2025-03-27T16:31:31.340Z","avatar_url":"https://github.com/marpple.png","language":"TypeScript","readme":"![Build Status](https://github.com/marpple/FxTS/actions/workflows/ci.yml/badge.svg)\n[![npm version](https://badge.fury.io/js/@fxts%2Fcore.svg)](https://badge.fury.io/js/@fxts%2Fcore)\n\n# ![fxts-icon](https://github.com/marpple/FxTS/assets/10924072/415500c9-12ce-4aec-8563-835514b94b22) FxTS\n\nFxTS is a functional library for TypeScript/JavaScript programmers.\n\n### Why FxTS?\n\n- Lazy evaluation\n- Handling concurrent requests\n- Type inference\n- Follow [iteration protocols](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Iteration_protocols) Iterable / AsyncIterable\n\n## Installation\n\n```\nnpm install @fxts/core\n```\n\n## Documentation\n\nPlease review the [API documentation](https://fxts.dev/docs/)\n\n## Usage\n\n```ts\nimport { each, filter, fx, map, pipe, range, take } from \"@fxts/core\";\n\npipe(\n  range(10),\n  map((a) =\u003e a + 10),\n  filter((a) =\u003e a % 2 === 0),\n  take(2),\n  each((a) =\u003e console.log(a)),\n);\n\n// chaining\nfx(range(10))\n  .map((a) =\u003e a + 10)\n  .filter((a) =\u003e a % 2 === 0)\n  .take(2)\n  .each((a) =\u003e console.log(a));\n```\n\n## Usage(concurrent)\n\n```ts\nimport { concurrent, countBy, flat, fx, map, pipe, toAsync } from \"@fxts/core\";\n\n// maybe 1 seconds api\nconst fetchWiki = (page: string) =\u003e\n  fetch(`https://en.wikipedia.org/w/api.php?action=parse\u0026page=${page}`);\n\nconst countWords = async (concurrency: number) =\u003e\n  pipe(\n    [\"html\", \"css\", \"javascript\", \"typescript\"],\n    toAsync,\n    map(fetchWiki),\n    map((res) =\u003e res.text()),\n    map((words) =\u003e words.split(\" \")),\n    flat,\n    concurrent(concurrency),\n    countBy((word) =\u003e word),\n  );\n\nawait countWords(); // 4 seconds\nawait countWords(2); // 2 seconds\n```\n\nyou can start [here](http://fxts.dev/docs/getting-started)\n\n## Build\n\n- `npm run build`\n\n## Running Test\n\n- `npm test`\n\n## Running Type Test\n\n- `npm run compile:check`\n\n## License\n\nApache License 2.0\n","funding_links":[],"categories":["TypeScript","Functional Programming","typescript","Libraries","Generic Utilities"],"sub_categories":["Runner","Reactive Programming"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarpple%2FFxTS","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmarpple%2FFxTS","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarpple%2FFxTS/lists"}