【发布时间】:2022-12-12 04:26:51
【问题描述】:
我正在使用 @angular/fire emulators 来模拟我的 firebase angular 应用程序中的身份验证过程。但是当我运行它时,我看到一条警告消息说“在模拟器模式下运行。不要使用生产凭证”:
我在github issues 中看到实现了一项功能以隐藏此消息。但我不知道该怎么做。
你知道我要这么做吗?
【问题讨论】:
标签: angular typescript firebase angularfire2
我正在使用 @angular/fire emulators 来模拟我的 firebase angular 应用程序中的身份验证过程。但是当我运行它时,我看到一条警告消息说“在模拟器模式下运行。不要使用生产凭证”:
我在github issues 中看到实现了一项功能以隐藏此消息。但我不知道该怎么做。
你知道我要这么做吗?
【问题讨论】:
标签: angular typescript firebase angularfire2
有点晚了,但这是我最近不得不处理的解决方案。
我检查了元素,发现警告消息有 css 类“.firebase 仿真器警告”
从那里我只是在 CSS 中定义样式来隐藏警告
/* making firebase emulator warning less intrusive */
.firebase-emulator-warning {
display: none';
}
然后我决定仍然展示它是个好主意,但要减少干扰。 为此,我使用了稍微不同的样式。
/* making firebase emulator warning less intrusive */
.firebase-emulator-warning {
background-color: transparent !important;
border: none !important;
color: rgba(245, 66, 66, 0.3) !important;
}
【讨论】: