{"id":16595426,"url":"https://github.com/nissy-dev/babel-plugin-remove-react-fc-and-vfc","last_synced_at":"2025-12-06T10:01:27.030Z","repository":{"id":46004119,"uuid":"430352712","full_name":"nissy-dev/babel-plugin-remove-react-fc-and-vfc","owner":"nissy-dev","description":"This plugin removes React.VFC and React.FC annotation","archived":false,"fork":false,"pushed_at":"2021-11-24T00:20:30.000Z","size":125,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-06T09:55:57.090Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/nissy-dev.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":"2021-11-21T11:55:49.000Z","updated_at":"2021-11-24T00:20:33.000Z","dependencies_parsed_at":"2022-09-05T09:12:20.301Z","dependency_job_id":null,"html_url":"https://github.com/nissy-dev/babel-plugin-remove-react-fc-and-vfc","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":"nissy-dev/babel-plugin-ts-template","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nissy-dev%2Fbabel-plugin-remove-react-fc-and-vfc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nissy-dev%2Fbabel-plugin-remove-react-fc-and-vfc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nissy-dev%2Fbabel-plugin-remove-react-fc-and-vfc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nissy-dev%2Fbabel-plugin-remove-react-fc-and-vfc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nissy-dev","download_url":"https://codeload.github.com/nissy-dev/babel-plugin-remove-react-fc-and-vfc/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242260096,"owners_count":20098471,"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-10-11T23:50:13.227Z","updated_at":"2025-12-06T10:01:21.995Z","avatar_url":"https://github.com/nissy-dev.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# babel-plugin-remove-react-fc-and-vfc\n\n![release](https://github.com/nissy-dev/babel-plugin-remove-react-fc-and-vfc/actions/workflows/release.yml/badge.svg)\n[![License: MIT](https://img.shields.io/github/license/nissy-dev/babel-plugin-remove-react-fc-and-vfc.svg)](https://opensource.org/licenses/MIT)\n[![npm version](https://badge.fury.io/js/babel-plugin-remove-react-fc-and-vfc.svg)](https://badge.fury.io/js/babel-plugin-remove-react-fc-and-vfc)\n\nThis plugin removes `React.VFC` and `React.FC` annotation.\n\nInput:\n\n```ts\nconst Component: React.FC\u003cProps\u003e = (props) =\u003e {\n  return \u003cdiv\u003e{props.value}\u003c/div\u003e;\n};\n```\n\nOutput:\n\n```ts\nconst Component = (props: Props) =\u003e {\n  return \u003cdiv\u003e{props.value}\u003c/div\u003e;\n};\n```\n\n## Why?\n\nAs `React.XXX` is modified frequently like [`React.SFC` was removed](https://github.com/DefinitelyTyped/DefinitelyTyped/pull/30364) or [the children type will be removed from React.FC](https://github.com/DefinitelyTyped/DefinitelyTyped/issues/46691), I think we should not use `React.XXX` type as much as possible.\n\nSee more details\n\n- [Remove React.FC from Typescript template](https://github.com/facebook/create-react-app/pull/8177)\n- [【検証】React.FC と React.VFC はべつに使わなくていい説](https://kray.jp/blog/dont-have-to-use-react-fc-and-react-vfc/)\n\n## Install\n\n```sh\n$ npm install --save-dev babel-plugin-remove-react-fc-and-vfc\n```\n\nand add it to your `.babelrc`.\n\n```json\n{\n  \"plugins\": [\"remove-react-fc-and-vfc\"]\n}\n```\n\n## Contributing\n\nWelcome your contribution!\n\nSee also [Babel Plugin Handbook](https://github.com/jamiebuilds/babel-handbook/blob/master/translations/en/plugin-handbook.md).\n\n## Setup\n\n```sh\n$ git clone git@github.com:nissy-dev/babel-plugin-remove-react-fc-and-vfc.git\n$ cd babel-plugin-remove-react-fc-and-vfc\n$ npm ci\n```\n\n## Development Tools\n\n```sh\n// run tsc, eslint, prettier\n$ npm run lint\n\n// run test\n$ npm run test\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnissy-dev%2Fbabel-plugin-remove-react-fc-and-vfc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnissy-dev%2Fbabel-plugin-remove-react-fc-and-vfc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnissy-dev%2Fbabel-plugin-remove-react-fc-and-vfc/lists"}