{"id":13768372,"url":"https://github.com/ilyalesik/gen-flow-files","last_synced_at":"2025-03-21T09:31:37.298Z","repository":{"id":44738110,"uuid":"166033085","full_name":"ilyalesik/gen-flow-files","owner":"ilyalesik","description":"Script for transform javascript files to flowtype definition files","archived":false,"fork":false,"pushed_at":"2022-01-27T17:02:43.000Z","size":275,"stargazers_count":28,"open_issues_count":3,"forks_count":8,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-17T23:44:42.313Z","etag":null,"topics":["flow","flowtype"],"latest_commit_sha":null,"homepage":"","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/ilyalesik.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":"2019-01-16T12:00:44.000Z","updated_at":"2022-10-15T09:54:38.000Z","dependencies_parsed_at":"2022-09-02T07:02:08.523Z","dependency_job_id":null,"html_url":"https://github.com/ilyalesik/gen-flow-files","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ilyalesik%2Fgen-flow-files","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ilyalesik%2Fgen-flow-files/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ilyalesik%2Fgen-flow-files/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ilyalesik%2Fgen-flow-files/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ilyalesik","download_url":"https://codeload.github.com/ilyalesik/gen-flow-files/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244771949,"owners_count":20507893,"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":["flow","flowtype"],"created_at":"2024-08-03T16:01:20.515Z","updated_at":"2025-03-21T09:31:36.983Z","avatar_url":"https://github.com/ilyalesik.png","language":"JavaScript","funding_links":[],"categories":["JavaScript","Tools"],"sub_categories":[],"readme":"# gen-flow-files\n\n[![npm version](https://img.shields.io/npm/v/gen-flow-files.svg)](https://www.npmjs.com/package/gen-flow-files)\n[![npm downloads](https://img.shields.io/npm/dt/gen-flow-files.svg)](https://www.npmjs.com/package/gen-flow-files)\n\nThis is a script which finds `.js` files with @flow annotation, extract flow definitions and save to specific folder.\n\nAs example, `\u003cinputDir\u003e/example.js`\n```javascript\n// @flow\n\nextract function foo(arg1: number, arg2: string): string {\n    // some code here\n}\n```\nwill be transformed to `\u003coutputDir\u003e/example.js.flow`:\n```javascript\n// @flow\n\ndeclare extract function foo(arg1: number, arg2: string): string;\n```\n\n## Installation\n\nInstall it with yarn:\n\n```\nyarn add gen-flow-files\n```\n\nOr with npm:\n\n```\nnpm i gen-flow-files --save\n```\n\n## Usage\n#### As part of build process\n\n```json\nscripts\": {\n    ...\n    \"flow\": \"flow\",\n    \"build:flow\": \"gen-flow-files src --out-dir dist\",\n    ...\n  },\n```\ntransfrom all *.js* files from `src` to *.js.flow* files and save them at `dist`. \n\n#### As command\n```\nnpx gen-flow-files \u003cinputDir\u003e --out-dir \u003coutputDir\u003e\n```\ntransfrom all *.js* files from `\u003cinputDir\u003e` to *.js.flow* files and save them at `\u003coutputDir\u003e`. \n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Filyalesik%2Fgen-flow-files","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Filyalesik%2Fgen-flow-files","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Filyalesik%2Fgen-flow-files/lists"}