jsx-refactor-utils
is an open-source npm library designed to streamline the process of analyzing and refactoring JSX code. With a focus on ease of use and extensibility, jsx-refactor-utils
provides developers with actionable insights to improve the maintainability and readability of their React codebase.
- 🧠 Smart Analysis: Leverages AST parsing to understand and evaluate your JSX code.
- 🛠️ Refactoring Suggestions: Provides clear, actionable refactoring recommendations.
- 📊 Complexity Reports: Generates complexity reports to identify areas that need simplification.
- 📝 Automated Docs: Auto-generates documentation for better code understanding.
- 🔧 Customizable Rules: Tailor the suggestions to fit your team's coding standards.
Install jsx-refactor-utils
using npm:
npm install jsx-refactor-utils --save-dev
or using yarn:
yarn add jsx-refactor-utils --dev
To analyze your JSX code and get refactoring suggestions, import and use jsx-refactor-utils
as follows:
const { analyzeCode, suggestRefactor } = require('jsx-refactor-utils');
const code = `<Your JSX Code Here>`;
const analysis = analyzeCode(code);
const suggestions = suggestRefactor(code);
console.log(analysis, suggestions);
For detailed documentation and API references, visit our GitHub Pages documentation.
Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement".
Don't forget to give the project a star! Thanks again!
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the MIT License. See LICENSE
for more information.
Project Link: https://github.com/vvk147/jsx-refactor-utils
Made with ❤️ by Vivek Yaligar