chore: vite vitest migration and different export types (ES Module, common js) - #531
Open
Puppo wants to merge 11 commits into
Open
chore: vite vitest migration and different export types (ES Module, common js)#531Puppo wants to merge 11 commits into
Puppo wants to merge 11 commits into
Conversation
- Replace Webpack build with Vite (UMD, ES, CJS formats) - Replace Jest with Vitest for testing - Rename .js files containing JSX to .jsx extension - Update tests to use Vitest API (vi instead of jest) - Add proper exports field in package.json
- Rename demo/js/demo.js to demo.jsx (JSX syntax requires .jsx extension) - Update demo/vite.config.js to: - Add commentsPlugin for /comments API middleware - Configure entry point and output filenames for proper bundling - Fix react-paginate alias path - Simplify demo/server.js by removing webpack-specific middleware - Add jquery dependency (was missing) - Add demo:build script for production builds Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
Co-authored-by: Copilot <copilot@github.com>
React 19 removed ReactDOM.findDOMNode() which caused all 99 tests to fail. Rewrote PaginationBoxView-test.jsx to use @testing-library/react queries (screen, within, fireEvent) instead of findDOMNode. Changes: - Replace ReactDOM.findDOMNode with screen queries and within helpers - Add hasClass() and getAttribute() helpers for DOM property access - Fix incorrect rel attribute assertion for single-page pagination - Keep dist/ changes (rebuilt with correct format output) Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
Rebuild dist files with proper format output. Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
- Set "type" to "module" in package.json - Upgrade eslint and eslint-plugin-react versions - Add eslint.config.js with recommended settings and custom rules Co-authored-by: Copilot <copilot@github.com>
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.
This PR moves the builder from WebPack to vite to handle UMD, CommonJS and ES Module formats.
Then it reviews the tests to use vitest instead of jest.
Lastly, it upgrades ESLint to v9.