@eda-plugin/eda
v1.0.0
Published
Auto export default generator for React/JSX/TSX files in src/**
Maintainers
Readme
📦 EDA - Auto Export Default Generator
EDA is a lightweight dev tool that automatically adds export default to your React/JSX/TSX component files inside src/**. Built for developers who move fast and forget to export their components — EDA’s got your back!
⚡ Features
- ✅ Watches your
src/**for new/changed files - ✅ Adds
export defaultto components automatically - ✅ Detects function/arrow component names
- ✅ Wraps anonymous JSX into named export
- ✅ Supports
.ts,.tsx,.js,.jsx - ✅ Built with Babel parser + traverse
🚀 Install
npm install -g eda🔧 Usage
edaBy default, it watches src/.
You can also specify a directory:
eda src/componentsIt will watch that folder and auto-export any new or updated component files.
🧠 Example
Before:
function Header() {
return <h1>Hello</h1>
}After EDA runs:
function Header() {
return <h1>Hello</h1>
}
export default Header;🧰 Internals
EDA uses:
@babel/parserto parse modern JS/TS@babel/traverseto extract component nameschokidarto watch file changes
🛠 Dev Commands
npm run build # build to dist
npm run dev # start in watch mode🤝 Contributing
Pull requests and issues are welcome! Feel free to fork the repo and improve the tool.
🧑💻 Author
Made with ❤️ by Mohammad Sajjad Hosan LinkedIn
📄 License
MIT License — free for personal and commercial use.
📌 TODOs
- [ ] Support auto write jsx or tsx basic structure
- [ ] Support auto-import + index.ts sync
- [ ] Add config file support
- [ ] Option to skip certain folders/files
