Following the barrel export pattern in React is a great way to organize your code. This extension will help you create barrel exports for your React components with a simple click.
How to use extension 🤔
Open the index.js/index.ts file in the folder you want to create a barrel export for.
Open the command palette by Ctrl+Shift+P or Cmd+Shift+P and search for Generate Barrel Export.
Enter the name of component you want to create a barrel export for.
A new folder will be created with the name of the component and an index.js/index.ts file will be created inside the folder.
The extension will automatically import all the files in the selected folder and export them.
Features 🚀
Create barrel export for React components
Separate component generation snippet for JavaScript and TypeScript
Requirements 📋
VS Code 1.41.0 or higher
React Project (JavaScript or TypeScript)
Release Notes 📝
Users appreciate release notes as you update your extension.
1.0.0
Initial release of React Barrel Export
Create barrel export for React components
Separate component generation snippet for JavaScript and TypeScript
1.0.1
Bugfix : new line issue fix in index file
1.0.2
Feature : Added named import for React Function Component