-
Notifications
You must be signed in to change notification settings - Fork 0
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
[VO-1227] chore: Migrate to Rsbuild #55
Open
cballevre
wants to merge
29
commits into
master
Choose a base branch
from
feat/migrate-to-rsbuild
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
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
552a4a3
to
a2d7795
Compare
a2d7795
to
98ac75f
Compare
BundleMonFiles added (17)
Files removed (9)
Files updated (2)
Total files change -444.43KB -13.49% Groups added (3)
Final result: ✅ View report in BundleMon website ➡️ |
zatteo
approved these changes
Dec 3, 2024
@cballevre very nice work |
Ldoppea
reviewed
Dec 10, 2024
This a mistake on the message 🙁 |
98ac75f
to
ca82d75
Compare
In cozy-script we used to enforce the development mode when doing a `yarn watch` The development mode changes the build behavior by removing some steps like minification which results to a faster build A side effect is that the code generated from the `watch` command is a bit different than the one generated from `build` command. This may produce some differences on the app's behavior, but this is rare enough (happened 1 or 2 times in the past years) so we consider the speed gain to still be valuable. Also we know that we should run a `build` locally as ultimate check before pushing new code to the git repo So we want to enable this mode in the new Rsbuild configuration Here are the timings for initial build and then 4 differents edits in the code that trigger a re-build yarn watch ``` 7,57s (initial build) 5,79s 5,83s 6,68s 7,15s ``` yarn watch --mode development ``` 7,00s (initial build) 0,69s 0,45s 0,92s 0,46s ``` Related code: https://github.com/cozy/create-cozy-app/blob/master/packages/cozy-scripts/scripts/watch.js#L13
ca82d75
to
588ab49
Compare
44e02d4
to
8f998c6
Compare
`rsbuild-config-cozy-app` has been upgraded to `0.2.0` in order to retrieve the configuration needed to run `rsbuild dev` with our cozy-stack based architecture and then benefits from HMR feature Related PR: cozy/cozy-libs#2700
Since previous commit we can run `rsbuild dev` to enable HMR feature We now have 3 different scripts: - `yarn build`: build the app for production - `yarn watch`: like for the `build` script but with some optimizations in order to build faster and to trigger rebuild automatically when the code changes - `yarn dev`: build the app with HMR enabled. This should be the fastest way to debug the app, but the HMR feature may prevent the app to work in some environments (i.e. flagship app)
5 tasks
zatteo
approved these changes
Jan 15, 2025
`rsbuild-config-cozy-app` has been upgraded to `0.2.1` in order to retrieve the configuration needed to run intents and public targets in the `rsbuild dev` mode Related PR: cozy/cozy-libs#2717
Non-regression tests have been done:
Performances comparison on my computer:
|
zatteo
approved these changes
Jan 30, 2025
`rsbuild-config-cozy-app` has been upgraded to `0.3.0` in order to retrieve the configuration needed to import images and static assets Related PR: [cozy/cozy-libs#2728](cozy/cozy-libs#2728)
zatteo
reviewed
Feb 11, 2025
<div role="application" data-cozy="{{.CozyData}}"></div> | ||
<% htmlPlugin.files.js.forEach(function(file) { %> | ||
<script defer src="<%- file %>"></script> | ||
<% }); %> |
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.
Any idea why there is no here ?
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.
Related PRs: