Skip to content

Latest commit

 

History

History
50 lines (37 loc) · 2.38 KB

File metadata and controls

50 lines (37 loc) · 2.38 KB

Test Project Documentation

This document provides an overview of the test project and how to work with it.

Running the Analysis

The test project is already configured to be analyzed by the react-package-analyzer. The configuration is in the react-import-analyzer.config.js file in this directory.

To run the analysis and generate the reports, run the following command from the root of the repository:

npx react-package-analyzer --config test-project/react-import-analyzer.config.js

The reports will be generated in the ../test-project-import-analysis directory.

Project Structure

The test-project directory contains a sample React application that uses components from the @mui/material and @chakra-ui/react libraries.

  • jsconfig.json: Configures the JavaScript compiler options, including path aliases.
  • react-import-analyzer.config.js: Configures the react-package-analyzer for this project.
  • src/: Contains the source code for the sample React application.
    • App.jsx: The main application component.
    • components/: Contains reusable UI components.
    • hooks/: Contains custom React hooks.
    • index.js: The entry point of the application.
    • pages/: Contains page components.
    • utils/: Contains utility functions.

Generated Reports

The test-project-import-analysis directory contains the reports generated by the react-package-analyzer.

  • components/: Contains detailed markdown reports for each component.
  • data/: Contains the raw JSON data generated by the analyzer.
    • dependency-chains.json: Maps relationships between files.
    • detailed.json: Comprehensive statistics about component usage.
    • import-intersections.json: Analysis of component import relationships.
    • raw.jsonl: Detailed component usage data for each file.
    • summary.json: High-level statistics about component usage.
  • features/: Contains markdown reports for each feature.
  • hubs/: Contains markdown reports for each hub.
  • components.md: An overview of all components.
  • features.md: An overview of all features.
  • files.md: An overview of all files.
  • hubs.md: An overview of all hubs.
  • index.md: The main markdown report.

For more detailed information about the generated reports, please see the main README.md file.