【问题标题】:Grey Areas in Webapp while using Firebase hosting使用 Firebase 托管时 Webapp 中的灰色区域
【发布时间】:2021-09-16 03:45:34
【问题描述】:

我有一个用 Flutter 编写的多页 Web 应用程序,它上传到 Firebase 托管。所有页面都可以正常工作,但主页的一半是灰色的。附照片。非常感谢您的帮助。

另外,我在运行时遇到此错误:flutter run -d chrome --release

Oops; flutter has exited unexpectedly: "ProcessException: The application has failed to start because its side-by-side configuration is incorrect. Please see the application event   
log or use the command-line sxstrace.exe tool for more detail.

  
Command: C:\Users\abc\AppData\Local\Google\Chrome\Application\chrome.exe --user-data-dir=C:\Users\abc\AppData\Local\Temp\flutter_tools.2b59d482\flutter_tools_chrome_device.4fad7966  --remote-debugging-port=2576 --disable-background-timer-throttling --disable-extensions --disable-popup-blocking --bwsi --no-first-run --no-default-browser-check
  --disable-default-apps --disable-translate http://localhost:11541".

【问题讨论】:

    标签: firebase flutter firebase-hosting


    【解决方案1】:

    在 Firebase 中托管 Web 应用时,我也遇到了同样的问题。

    问题不在 firebase 主机中。问题出在您的代码中。您的代码将完全在调试模式下工作。但不在发布模式下。

    1. 检查日志中的每个警告。
    2. 这主要是因为错误使用了扩展或灵活的小部件

    【讨论】:

    • 明白了。所以在部署之前应该解决每个错误?
    • 是的,在我的情况下,这是由于扩展的小部件。它会引发警告,例如不正确使用父母数据小部件。
    • 您是否有任何警告,例如错误使用父母数据小部件?在日志中
    • 其实,我调试了所有的错误,但仍然可以使用灰色区域。我也在我的项目中使用了 firestore。我正在添加 firebase sdk 看看问题是否是 firebase 其他产品
    • 检查您的网站是否在发布模式下工作?
    猜你喜欢
    • 2020-10-12
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2019-06-27
    • 2019-10-01
    • 2017-10-02
    • 2021-04-10
    相关资源
    最近更新 更多