Skip to content
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

Replace webpack and CRA with vite #281

Closed
wants to merge 10 commits into from
Closed

Conversation

fwextensions
Copy link
Collaborator

@fwextensions fwextensions commented Mar 23, 2023

Wrestled vite into submission.

Move index.html to root directory. 🙄
Import the CJS modules using `import *` syntax to get the compile errors to stop, though it probably won't work.
Add vite, react plugin and vite.config.js.
Without it, we can't access the vite dev server from outside docker.
Use * instead of the file: path for the shared package, so that changes are picked up immediately.
Use the correct comboBox import instead of using a relative path to node_modules.
Change convertToPropType.js to ESM.
Add shared to the workspaces array.
Tell prettier to ignore vite.config.js.
Clarify how sub-package imports work with shared.
Move the test command into e2e/package.json from the playwright config.
Clean up client/package.json.
Seriously, go away prettier.
@fwextensions fwextensions force-pushed the jdunning/feat/try-vite branch from 0c50c5b to d39320e Compare March 23, 2023 20:35
Move dev deps to devDeps in client/package.json.
Remove setupProxy.js, which is no longer needed.
Avoids having to use ../shared in optimizeDeps inside vite.config.js.
Update shared/README.md with info on the difference.
@fwextensions fwextensions force-pushed the jdunning/feat/try-vite branch from 3eba4f4 to 1a38234 Compare March 24, 2023 01:03
That command never finishes, so having it in the e2e test script means playwright never gets started.
@fwextensions fwextensions changed the title Replace webpack with vite Replace webpack and CRA with vite Mar 24, 2023
@fwextensions
Copy link
Collaborator Author

@francisli this branch seems to be fully working now, if you want to take a look.

Do you know where the path to /client/build is specified for the server? The default build folder for Vite is dist, and the server wasn't finding that during CI/CD.

@francisli
Copy link
Collaborator

Closing in favor of #315

@francisli francisli closed this Sep 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants