firebase / firebase/firebase-admin-node
Firebase Firstore Doc.Get does not let angular universal to resolve
还没有人认领这个 Issue。
- 主要语言
- TypeScript
- 星标
- 1.7k
- 派生
- 419
- 平均合并
- 3 天 10 小时
- 30 天内合并 PR
- 16
描述
I'm reporting for the first time so if I'm making some mistake let me know.
The thing is that I'm working on an angular app that uses angular universal and firebase as backend. When hosting, i use a cloud function to Server-Side Render the website for SEO and preview, as usual.
But, it took me 4 weeks to discover what was wrong with my code, at some point, the ssr just stopped working. The request to ssr function always times out.
Then last week I've been rewriting the WHOLE app, and testing it step by step, until i notice a bug that happens when working with angular and firebase-admin (firestore, to be more precise)
When I insert a firestore.collection('collectionPath').doc('docId').get() the ssr part of the app just stopped working. There's something inside this that holds angular to return the html response. I've been conducting lots of testing, indeed, the get request works normally.
I've followed the whole callstack and there's something that holds angular in place preventing the returning.
I make two more requests at the same time, the first was a query, taht worked perfectly. When i inserted the doc().get(), it stopped working. I'm not able to give you more details because I'm noob in this kind of thing, but if you beed any additional let me know.
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
使用 Cloud Function 和 firebase-admin Firestore,在 Angular Universal 的服务器端渲染中重现超时,并将集合查询与 collection('collectionPath').doc('docId').get() 进行比较。跟踪文档获取操作周围的调用栈;当 SSR 返回 HTML 且不发生超时时,问题即得到解决。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- angular, firebase, node.js, typescript
- 领域
- backend, databases, web-dev
- Issue 类型
- 缺陷
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 活跃度
- 停滞
- 描述清晰度
- 需要澄清
- 新手友好度
- 25/100