-
Notifications
You must be signed in to change notification settings - Fork 37
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
refactor: migrate from webpack to vitejs bundler #240
Merged
Merged
Conversation
This file contains 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
Removed the `.eslintrc` file that defined the project's ESLint rules and settings. This change might impact linting automation and developer workflows which relied on these configurations.
Changes across project files to use dynamically import format suggested by vitejs
- Renamed 'public/index.html' to 'index.html' - Updated paths for manifest and favicon links to relative paths - Removed unnecessary 'noscript' tag - Added script tag to load 'index.tsx'
- Update `package.json` to add Vite as the build and start tool. - Remove `react-scripts` and associated dependencies. - Add Vite and related plugins to `devDependencies`. - Create `vite.config.ts` to configure Vite with environment variables and path aliases.
- Replaced single tsconfig.json with tsconfig.app.json and tsconfig.node.json - tsconfig.app.json setup for application-specific settings - tsconfig.node.json tailored for Node.js-specific settings
Introduce a new ESLint configuration to maintain code quality and consistency. The config: - Utilizes recommended settings from ESLint and TypeScript - Integrates plugins for React hooks and React Refresh - Ignores the 'dist' directory to avoid linting built files
- Created `src/init.js` to ensure `window.global` is defined. - This change prevents potential issues with environments lacking `global` definition.
- Update `package.json` to add Vite as the build and start tool. - Remove `react-scripts` and associated dependencies. - Add Vite and related plugins to `devDependencies`. - Create `vite.config.ts` to configure Vite with environment variables and path aliases.
Removed the vite-plugin-simple-html package from the dependencies in package.json as it is no longer needed. This helps simplify the dependency graph and reduces potential security vulnerabilities. No other changes in the package functionality were affected.
Introduce a new Makefile to streamline development tasks. - Auto-load environment variables from .env file. - Set default goal, silence make output. - Add targets for running tests, test coverage, and linting.
This commit focuses on a variety of code optimizations and improvements: - Removed unused imports from several files. - Optimized imports by using '@src' alias in various files. - Improved code formatting for better readability.
This commit fixes the lint command in the Makefile to ensure proper execution. - Removed an unnecessary unintended backslash at the end of the eslint command. - Ensures that eslint will run correctly on all specified file types.
- Removed unnecessary eslint-disable-next-line no-empty-pattern. - Ignored TypeScript error for unused variable in movie-details-description. - Cleaned up props in MovieDetailsDescription component.
Updated CarouselItem and CarouselLargeItem components to use Readonly type for their props to ensure immutability. - Modified CarouselLargeItem in carousel-mixed.tsx. - Modified CarouselItem in carousel-main.tsx.
|
Jadapema
approved these changes
Nov 5, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
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 pull request includes significant changes to the project configuration and codebase, focusing on migrating to Vite, updating ESLint configuration, and refactoring import paths for consistency. The most important changes include the removal of the
.eslintrc
file, the addition of aneslint.config.js
file, updates topackage.json
to support the Vite build tool, and numerous import path updates across various files.Configuration Updates:
.eslintrc
file and replaced it with aneslint.config.js
file, introducing a new ESLint configuration that includes plugins for React hooks and refresh. [1] [2]package.json
to replacereact-scripts
with Vite, added necessary Vite plugins, and adjusted thestart
andbuild
scripts to use Vite. [1] [2] [3] [4] [5] [6]HTML and Asset Updates:
public/index.html
toindex.html
and updated paths for manifest and favicon files, as well as added a script tag to load the main entry point. [1] [2]Import Path Refactoring:
src/App.tsx
to use absolute paths with the@src
alias for improved consistency and maintainability. [1] [2]_mock
files to use the@src
alias. [1] [2] [3] [4]@src
alias. [1] [2] [3]@src
alias. [1] [2] [3] [4] [5] [6] [7] [8]