在使用 Firebase 时,使用:
% firebase experiments:enable webframeworks
运行以下命令后:
% firebase deploy
我看到这条消息(我不记得以前见过)出现在终端中:
No Firebase app associated with site nice-guy,
injecting project default config.
You can link a Web app to a Hosting site here
https://console.firebase.google.com/project/niceguy-5e3c2/settings/general/web
我去了指定的地址,但不知道在那里做什么。
如果有人知道我应该根据上面的消息做什么,我会很高兴获得一些相关信息。
附注
这里还有一个细节。我注意到只有当我将此行添加到 firebase.json 时才会出现此问题:
"site": "nice-guy",
这不是我第一次插入这样的行。
可能与:实验:启用网络框架有关 我几乎是第一次使用。
作为参考,可以在下面看到 firebase.json 文件的内容:
% cat firebase.json
{
"hosting": {
"source": ".",
"site": "nice-guy",
"ignore": [
"firebase.json",
"**/.*",
"**/node_modules/**"
],
"frameworksBackend": {
"region": "asia-east1"
}
}
}
%
尝试进行以下更改
第一个尝试将
"site": "nice-guy"
替换为 "site": "niceguy-5e3c2"
或 "site": "nice-guy-5e3c2"
,可能行不通,但试试吧。
如果无法解决,请尝试删除
"source": "."
和 "site": "nice-guy"
,然后添加 "public":"path to the production folder"
,如下所示
{
"hosting": {
"public":"path to the production folder most of the case it is in dist/appName"
"ignore": [
"firebase.json",
"**/.*",
"**/node_modules/**"
],
"frameworksBackend": {
"region": "asia-east1"
}
}
}