Refactor: Transition to TypeScript and Webpack build system#449
Merged
Refactor: Transition to TypeScript and Webpack build system#449
Conversation
…om/CropperBlazor/Cropper.Blazor into feature/add_typescript_for_project
…om/CropperBlazor/Cropper.Blazor into feature/add_typescript_for_project
Contributor
There was a problem hiding this comment.
Pull request overview
This PR refactors the build system from JavaScript with Excubo.WebCompiler to TypeScript with Webpack, bringing modern tooling, type safety, and comprehensive testing infrastructure to the project.
Changes:
- Migrated JavaScript codebase to TypeScript with strict type checking and namespace organization
- Replaced Excubo.WebCompiler with Webpack build system including source maps, code splitting, and TypeScript declaration generation
- Integrated Vitest for JavaScript/TypeScript testing, ESLint for linting, and Prettier for code formatting
Reviewed changes
Copilot reviewed 36 out of 42 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| webpack.config.js | New Webpack configuration with TypeScript compilation, CSS processing, and declaration file generation |
| package.json | npm dependencies for TypeScript tooling, testing (Vitest), linting (ESLint), and build tools |
| tsconfig.json | TypeScript configuration with strict mode and ES2020 target |
| Cropper/cropperJsInterop.ts | Main TypeScript file migrated from JS with type definitions and namespace organization |
| Cropper/helpers/*.ts | Helper utilities extracted into TypeScript modules with comprehensive type safety |
| Cropper/types/**/*.d.ts | TypeScript type definitions for .NET interop and Cropper.js integration |
| eslint.config.cjs | ESLint configuration for TypeScript (has critical bug) |
| vitest.config.ts | Vitest test configuration with coverage support |
| Cropper.Blazor.csproj | Updated build targets to integrate npm/Webpack into MSBuild process |
| .github/workflows/*.yml | CI/CD updates to run JavaScript tests and linting |
| cropperJsInterop.js | Removed original JavaScript implementation |
| cropper.min.js/css | Now copied from node_modules instead of being committed |
| excubowebcompiler.json | Removed old build configuration |
| .config/dotnet-tools.json | Removed Excubo.WebCompiler tool |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…om/CropperBlazor/Cropper.Blazor into feature/add_typescript_for_project
ColdForeign
previously approved these changes
Feb 3, 2026
…ix error during blazor server prerendering in dispose methods (#453) ## Target <!-- Why are you making this change? --> - Add receiver components to docs - Fix events cropper component desc - Fix error during blazor server prerendering in dispose methods #### Open Questions <!-- OPTIONAL - [ ] Use the GitHub checklists to spark discussion on issues that may arise from your approach. Please tick the box and explain your answer. --> ## Checklist <!-- It serves as a gentle reminder for common tasks. Confirm it's done and check everything that applies. --> - [x] Tests cover new or modified code - [x] I have performed a self-review of my own code - [ ] I have commented my code, particularly in hard-to-understand areas - [x] I have made corresponding changes to the site documentation - [ ] I have made corresponding changes to the README, NuGet README file - [x] My changes generate no new warnings - [ ] New dependencies added or updated - [ ] Includes breaking changes - [ ] Version bumped ## Visuals <!-- OPTIONAL Show results both before and after this change. When the output changes, it can be a screenshot of a trace, metric, or log illustrating the change. --> --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
ColdForeign
approved these changes
Feb 3, 2026
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## dev #449 +/- ##
============================================
- Coverage 100.00% 81.02% -18.98%
============================================
Files 26 29 +3
Lines 739 938 +199
Branches 44 65 +21
============================================
+ Hits 739 760 +21
- Misses 0 177 +177
- Partials 0 1 +1
☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Target
Open Questions
Checklist
Visuals