首页 > 解决方案 > 优化 Expo build:web

问题描述

我已经在 React Native 中为 iOS 和 Android 构建了一个应用程序,但我也想通过 Web 应用程序提供。这一切都很好,但网络应用程序的性能是一个问题。

文件大小构建为 2.02MB。有没有办法在不影响我的原生构建的情况下优化它?

asset size limit: The following asset(s) exceed the recommended size limit (586 KiB).
This can impact web performance.
Assets:
 ./fonts/MaterialCommunityIcons.ttf (665 KiB)
 static/js/2.4f7a5c.chunk.js (2.02 MiB)

entrypoint size limit: The following entrypoint(s) combined asset size exceeds the recommended limit (586 KiB). This can impact web performance.
Entrypoints:
 app (2.11 MiB)
     static/js/runtime~app.4b5a04.js
     static/js/2.8f75c.chunk.js
     static/js/app.59c50.chunk.js

标签: reactjsreact-nativeexporeact-native-web

解决方案


推荐阅读