-
-
Notifications
You must be signed in to change notification settings - Fork 6.8k
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
build: migrate from CRA to Vite 🎉 #6441
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Ignored Deployment
|
Wow this is great @wesbragagt 🚀 |
575f8f4
to
cff0a2b
Compare
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.
I have Revert TS config changes, probably those were pushed mistakenly @wesbragagt ?
The flags are not working well so checking that
Hum, it should pick that up. I will take a look. Likely the the way vite is picking up .env files. |
@wesbragagt any update on this ? |
Rethinking on this - I think its better we migrate to |
Ok I was able to make it work (Its how Vite works, vite gives preference to .env.developement over .env.local unlike CRA) but I am still worried about the compatibility support as the library is almost 2 years old (still not officially recommended in docs) so I am little worried if its up to date with all things which Vite supports / will support in future. So I will update it to using Vite vars. |
@excalibot trigger release |
@ad1992 Preview version has been shipped 🚀 |
@excalibot trigger release |
@ad1992 Preview version has been shipped 🚀 |
As I am trying out fully to migrate to Vite, its a big change and significantly different from this PR hence I will open a separate PR so its easier to visualise the diff and keep this open as well so if the full migration doesn't work out we can still merge with current state. Hence I will also revert the vite and webpack related changes in this PR and push it in a separate PR instead |
@ad1992 Sounds like a good plan, I'm excited for the release! |
Vite is merged so closing this in favour of #6713 |
Hey lovely folks 👋 , I'm a long time fan of Excalidraw and I'm working on a live workshop showing folks how to migrate a fairly large application from CRA to Vite. I chose to try it out with this project since its built with CRA.
I was very excited to see it working with Vite and decided to put together this PR for everyone to check it out and see if its something worth considering.
Progress so far:
Tests are still using react-scripts but I intend to explore getting Vitest to work.
Test:
yarn start
Watch the blazingly fast HMRyarn build
Pretty darn fast tooyarn build:preview
Build and serve a production version locallyResults:
CRA Build before
Vite Build after