I have firebase hosting setup currently redirecting to index.html like this.
{
"database": {
"rules": "database.rules.json"
},
"hosting": {
"public": "build",
"rewrites": [
{
"source": "**",
"destination": "/index.html"
},
{
"source": "/details/**",
"function": "details"
}
]
}
}
But I want to redirect the request based on user-agents like Facebot for Facebook ...
Is there a way to redirect request on firebase hosting before reaching on cloud function? I know it's possible inside the function but I would love to do it on the hosting configuration.