Skip to content

frontend: set vite/esbuild build target to chrome 122 #3327

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

thisconnect
Copy link
Collaborator

Qt was upgraded to 6.8.2 which includes a newer chromium version in 84a8a71

Bumped build target in vite config, this saves a few bytes.

Browserlist in package.json seems to be only supported by vite plugin-legacy, see:

Removed Browserlist in package.json.

Before asking for reviews, here is a check list of the most common things you might need to consider:

  • updating the Changelog
  • writing unit tests
  • checking if your changes affect other coins or tokens in unintended ways
  • testing on multiple environments (Qt, Android, ...)
  • having an AI review your changes

Qt was upgraded to 6.8.2 which includes a newer chromium version
in 84a8a71

Bumped build target in vite config, this saves a few bytes.

- BitBoxSwiss@84a8a71
- https://wiki.qt.io/QtWebEngine/ChromiumVersions
- https://vite.dev/guide/build#browser-compatibility
- https://esbuild.github.io/api/#target

Browserlist in package.json seems to be only supported by vite
plugin-legacy, see:
- https://github.com/vitejs/vite/tree/main/packages/plugin-legacy#targets

Removed Browserlist in package.json.
@thisconnect
Copy link
Collaborator Author

thisconnect commented May 6, 2025

% find ./frontends/web/build/assets/. -type f \( -name "*.js" -o -name "*.css" \) -exec stat -f%z {} + | awk '{total += $1} END {print total " bytes"}'

reduced JS/CSS size from 3786138 bytes to 3781795 bytes

@benma
Copy link
Contributor

benma commented May 6, 2025

% find ./frontends/web/build/assets/. -type f \( -name "*.js" -o -name "*.css" \) -exec stat -f%z {} + | awk '{total += $1} END {print total " bytes"}'

A slightly simpler command (the above didn't even work for me because of % not being recognized somehow):

 cd frontends/web/build/assets/ && du -sc {*.js,*.css}

@thisconnect
Copy link
Collaborator Author

A slightly simpler command (the

😅 hehe thanks. yeah I can't bash 🙈 , my geepeetee-friend helped with this and it just worked.

@thisconnect thisconnect requested a review from shonsirsha May 6, 2025 15:10
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