{"id":23174589,"url":"https://github.com/vscodeshift/function-codemorphs","last_synced_at":"2025-04-05T00:43:26.204Z","repository":{"id":40783754,"uuid":"237724529","full_name":"vscodeshift/function-codemorphs","owner":"vscodeshift","description":"commands for refactoring functions","archived":false,"fork":false,"pushed_at":"2023-01-05T06:15:51.000Z","size":783,"stargazers_count":1,"open_issues_count":23,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-10T09:15:16.357Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/vscodeshift.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-02-02T05:39:36.000Z","updated_at":"2023-12-21T10:01:51.000Z","dependencies_parsed_at":"2023-02-03T15:16:17.423Z","dependency_job_id":null,"html_url":"https://github.com/vscodeshift/function-codemorphs","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vscodeshift%2Ffunction-codemorphs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vscodeshift%2Ffunction-codemorphs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vscodeshift%2Ffunction-codemorphs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vscodeshift%2Ffunction-codemorphs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vscodeshift","download_url":"https://codeload.github.com/vscodeshift/function-codemorphs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247271492,"owners_count":20911586,"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":[],"created_at":"2024-12-18T05:30:18.310Z","updated_at":"2025-04-05T00:43:26.156Z","avatar_url":"https://github.com/vscodeshift.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @vscodeshift/function-codemorphs\n\n[![CircleCI](https://circleci.com/gh/vscodeshift/function-codemorphs.svg?style=svg)](https://circleci.com/gh/vscodeshift/function-codemorphs)\n[![Coverage Status](https://codecov.io/gh/vscodeshift/function-codemorphs/branch/master/graph/badge.svg)](https://codecov.io/gh/vscodeshift/function-codemorphs)\n[![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release)\n[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg)](http://commitizen.github.io/cz-cli/)\n[![Visual Studio Marketplace Version](https://img.shields.io/visual-studio-marketplace/v/vscodeshift.function-codemorphs)](https://marketplace.visualstudio.com/items?itemName=vscodeshift.function-codemorphs)\n\nCommands for refactoring functions\n\n# Convert arrow function body to block statement\n\n### Before\n\n```js\nconst foo = () =\u003e 'foo!'\n```\n\nPosition cursor anywhere in the arrow function and then run the\n**Convert arrow function body to block statement** command.\n\n### After\n\n```js\nconst foo = () =\u003e {\n  return 'foo!'\n}\n```\n\n# Convert arrow function body to expression\n\nThe inverse of the above. The function body must consist only of\na `return` statement or this will error out.\n\n### Before\n\n```js\nconst foo = () =\u003e {\n  return 'foo!'\n}\n```\n\nPosition cursor anywhere in the arrow function and then run the\n**Convert arrow function body to expression** command.\n\n### After\n\n```js\nconst foo = () =\u003e 'foo!'\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvscodeshift%2Ffunction-codemorphs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvscodeshift%2Ffunction-codemorphs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvscodeshift%2Ffunction-codemorphs/lists"}