-
Notifications
You must be signed in to change notification settings - Fork 5
Add React Router and refactor dashboard with enhanced minification benchmarks featuring optimized compression sorting and detailed metrics #49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Co-authored-by: Boshen <[email protected]>
Co-authored-by: Boshen <[email protected]>
|
@copilot create a new page and a new file for this feature. |
Co-authored-by: Boshen <[email protected]>
Co-authored-by: Boshen <[email protected]>
I've separated the minification benchmarks feature into dedicated components as requested. The implementation now includes:
This provides better code organization and maintainability while preserving all existing functionality. Commit: 087f7c4 |
|
@copilot add react router and move the page to another route. |
Co-authored-by: Boshen <[email protected]>
Added React Router with proper page routing. The application now uses dedicated routes ( |
|
@copilot add a chart for each library for minification benchmark |
Co-authored-by: Boshen <[email protected]>
Added individual charts for each library in the minification benchmarks. The page now displays 12 separate charts (one for each JavaScript library: React, Vue, jQuery, Lodash, D3, etc.) showing how different minifiers perform on each specific library. Each chart is interactive with tooltips and switches between minification time and compression ratio metrics. Commit: 718483f |
|
@copilot display numbers on top of the bar charts. |
|
@copilot for each bar chart, display numbers from smallest to largest |
Co-authored-by: Boshen <[email protected]>
Sorted all bar charts to display values from smallest to largest. This applies to both Rolldown Stats (Bundle Size and Build Time) and all individual library charts in Minification Benchmarks (both Time and Compression Ratio metrics). The sorting makes it much easier to compare performance across different tools and identify the best performers. Commit: fd916cf |
|
@copilot combine the minification tabs, the left column shows minification time, right column shows compression size. Also sort the rows by larger library size first. |
Co-authored-by: Boshen <[email protected]>
Combined the minification tabs into a two-column layout showing minification time (left) and compression size (right) for each library. Libraries are now sorted by file size from largest to smallest (TypeScript → Ant Design → ECharts → Victory → etc.). The new layout eliminates tab switching while providing comprehensive side-by-side performance comparisons. Commit: 7cfdc8d |
|
@copilot use |
…culation Co-authored-by: Boshen <[email protected]>
Updated compression ratio calculation to use |
|
@copilot for Compression Ratio, changed it to also display minzippedBytes, display the largest compression ratio on the left and smallest on the right. |
… minzippedBytes in tooltips Co-authored-by: Boshen <[email protected]>
Updated compression ratio charts to display minzippedBytes in tooltips and sort from largest compression ratio (left) to smallest (right). The tooltips now show both the percentage and exact minzippedBytes values (e.g., "88.7% (8186 bytes)"), and the bars are arranged with the best-performing minifiers on the left. Commit: 3e0e3a5 |





This PR refactors the monolithic dashboard implementation by separating features into dedicated components and adds React Router for proper page routing with distinct URLs. Additionally, it enhances the minification benchmarks with a combined two-column layout that eliminates tab switching and provides comprehensive performance comparisons using real-world compression metrics with optimized sorting and detailed tooltip information.
What Changed
🛣️ React Router Integration
react-router-domdependency for client-side routing/for Rolldown Stats,/minificationfor Minification Benchmarks)components/Layout.tsx: Created layout component with shared navigation using React Router Links🔧 Component Architecture Improvements
pages/RolldownStatsPage.tsx: Dedicated page component for Rolldown statistics with its own header and statepages/MinificationBenchmarksPage.tsx: Dedicated page component for minification benchmarks with its own header and stateMinificationBenchmarks.tsx: Extracted all minification benchmark functionality into a reusable componentRolldownStats.tsx: Created a separate component for Rolldown statisticsApp.tsx: Simplified to handle only routing configuration using React Router📊 Enhanced Minification Benchmarks with Combined Layout
📈 Optimized Chart Visualization and Sorting
⚙️ Real-World Compression Metrics with Detailed Information
minzippedBytesinstead ofminifiedBytesfor accurate representation of actual file sizes served over HTTP with gzip compression✨ Enhanced User Experience
📈 Preserved Functionality
All existing features remain exactly the same:
This refactoring provides a modern, scalable architecture that follows React best practices for component composition and routing while significantly improving the user experience. The new combined layout with optimized sorting and detailed metrics eliminates the friction of tab switching and provides a more comprehensive view of minification performance across different JavaScript libraries with real-world compression metrics that better reflect production usage.
Fixes #48.
💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.