SAP Spartacus SSR模式启用失败的一个原因:SSR rendering exceeded timeout
https://github.com/SAP/spartacus/issues/10638
錯誤消息:SSR rendering exceeded timeout, fallbacking to CSR for /
解決方案
it’s a side effect of a new of SSR optimization feature available in Spartacus 3.0 and up.
It is possible to either extend the timeout in server.ts (passing a second parameter to NgExpressEngineDecorator.get method) or set it to 0, so it won’t be fallbacking to CSR at all. Here is an example:
const ngExpressEngine = NgExpressEngineDecorator.get(engine, { timeout: 0 });You can use API documentation to get a list of available options:
https://sap.github.io/spartacus/interfaces/SsrOptimizationOptions.html
Additionally, an extended documentation regarding this feature and best practices is on its way.
也可以參考這個文檔,進行SAP Spartacus SSR的調試:
How to Debug a Server–Side Rendered Storefront
總結
以上是生活随笔為你收集整理的SAP Spartacus SSR模式启用失败的一个原因:SSR rendering exceeded timeout的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 大学生创业贷款可以贷多少钱,大概能贷10
- 下一篇: Arm 宣布向美国递交 IPO 申请书,