Я исправил его, изменив файл firebase.json на следующее:
"rewrites": [{ "source": "/public/**", "destination": "/public.html" }, { "source": "**", "destination": "/index.html" }]