在VS Code中调试Firebase Cloud函数

问题描述 投票:1回答:1

我在Flutter应用程序中使用Firebase Cloud Functions。但是我无法调试我的云功能。


我尝试了什么?

首先,我尝试了this

并运行firebase emulators:start --inspect-functions。它给了我这个错误。

enter image description here


我尝试过this。但是firebase setup:web已弃用。这就是为什么我也停留在这里。


我安装了npm i @google-cloud/functions-framework。然后我像这样创建并配置了launch.json和settings.json。

enter image description here enter image description here

然后运行node --inspect node_modules/@google-cloud/functions-framework --target=listGoogleAPIs


但是它给了我这个错误:Provided code is not a loadable module. Could not load the function, shutting down. Waiting for the debugger to disconnect...


我的代码就是这样:

enter image description here

有人可以指导我进行配置吗?

firebase google-cloud-functions vscode-debugger
1个回答
0
投票
© www.soinside.com 2019 - 2024. All rights reserved.