我将目标添加到了Firebase项目中,因为将会有子域。我以前做过此操作,但从未遇到此错误。因此,我在firebase控制台中创建了该项目。然后我在终端中打开了项目。
firebase init
... chose existing project // Website
firebase deploy // website is now live at firebase domain
然后我添加了一个目标...
firebase target:apply hosting website Website
现在我转到了firebase.json文件,它看起来像这样
{
"hosting": {
"target": "website" // this causes Error: 404, Requested entity was not found
"public": "build",
"ignore": [
"firebase.json",
"**/.*",
"**/node_modules/**"
],
"rewrites": [
{
"source": "**",
"destination": "/index.html"
}
]
}
}
添加该目标并在终端中运行firebase deploy之后,出现错误。也许我也需要将目标添加到我的firebase.rc中?