{"id":21074788,"url":"https://github.com/dawsbot/json-fn-file","last_synced_at":"2025-10-14T18:07:14.863Z","repository":{"id":57284856,"uuid":"80335279","full_name":"dawsbot/json-fn-file","owner":"dawsbot","description":"Apply a function to a json file and save to a file","archived":false,"fork":false,"pushed_at":"2017-12-15T19:03:12.000Z","size":36,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-09-15T11:13:27.931Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/dawsbot.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}},"created_at":"2017-01-29T08:01:29.000Z","updated_at":"2017-01-31T04:38:33.000Z","dependencies_parsed_at":"2022-08-25T07:33:16.743Z","dependency_job_id":null,"html_url":"https://github.com/dawsbot/json-fn-file","commit_stats":null,"previous_names":["dawsonbotsford/json-fn-file"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dawsbot/json-fn-file","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dawsbot%2Fjson-fn-file","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dawsbot%2Fjson-fn-file/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dawsbot%2Fjson-fn-file/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dawsbot%2Fjson-fn-file/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dawsbot","download_url":"https://codeload.github.com/dawsbot/json-fn-file/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dawsbot%2Fjson-fn-file/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279016284,"owners_count":26085827,"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-13T02:00:06.723Z","response_time":61,"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-19T19:17:57.444Z","updated_at":"2025-10-14T18:07:14.807Z","avatar_url":"https://github.com/dawsbot.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# json-fn-file\n[![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![XO code style][xo-image]][xo-url]\n\n\u003e Apply a function to a json file and save to a file\n\n## Install\n\n```\nnpm install --save json-fn-file\n```\n\n## Usage\n\n```js\nconst jsonFnFile = require('json-fn-file');\n\n// Assuming \"input.json\" contains:\n//  {\n//    \"key1\": \"Value1\",\n//    \"key2\": \"Value2\"\n//  }\njsonFnFile('input.json', 'output.txt', input =\u003e Object.keys(input));\n//=\u003e 'key1,key2'\n```\n\n## API\n\n### jsonFnFile(inputFile, outputFile, fn)\n\n#### Arguments\n\n| Name       | Description                     |   Type   |  Default  |\n| -------    | ------------------------------- | -------- |  -------  |\n| inputFile  | File path to input **json** file    | `string` | None (required) |\n| outputFile | File path to output file        | `string` | None (required) |\n| fn         | Converter function to run on json | `function` | (in) =\u003e (in) |\n\nYour function will be fed one argument, the json content of `inputFile`.\n\n#### Returns\n\nType: `object`\n\n## License\n\nMIT © [Dawson Botsford](http://dawsonbotsford.com)\n\n[npm-image]: https://badge.fury.io/js/json-fn-file.svg\n[npm-url]: https://npmjs.org/package/json-fn-file\n[travis-image]: https://travis-ci.org/dawsbot/json-fn-file.svg?branch=master\n[travis-url]: https://travis-ci.org/dawsbot/json-fn-file\n[xo-image]: https://img.shields.io/badge/code_style-XO-5ed9c7.svg\n[xo-url]: https://github.com/sindresorhus/xo\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdawsbot%2Fjson-fn-file","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdawsbot%2Fjson-fn-file","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdawsbot%2Fjson-fn-file/lists"}