本文介绍了从Chrome开发者工具调试Firestore网络请求的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我希望使用Angular + Google Cloud Firestore调试从表单触发的请求,以确保它不会触发得太频繁.当我转到Chrome开发者工具中的网络"标签时,我看到一条请求正在通过 https://firestore.googleapis.com/... ,但是响应数据已经过编码,看起来像这个:

Using Angular + Google Cloud Firestore, I was hoping to debug a request fired from a form to make sure it wasn't firing too often. When I go to the Network tab in Chrome dev tools, I see a request going through to https://firestore.googleapis.com/..., but the response data is encoded and looks something like this:

8
[1,4,7]

在我对firestore的基本理解中,我认为请求看起来像这样,因为firestore在后台使用了gRPC.我来自REST/JSON背景,因此这对我来说是新领域.有没有更好的方法来调试这样的请求?

In my very basic understanding of firestore, I think the requests looks this way because of firestore's use of gRPC under the hood. I come from a REST/JSON background so this is new territory for me. Is there a better way to debug requests like this?

推荐答案

可以在 network 标签的 XHR 选项下看到Cloud Firestore请求响应.检查这张图片.

Cloud Firestore request response can be seen under XHR option in network tab.Check this image.

这篇关于从Chrome开发者工具调试Firestore网络请求的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-29 14:55