Unable to add Firebase Dynamic Links to a project using a custom domain

后端 未结 6 2068
栀梦
栀梦 2021-02-05 01:30

I\'ve created Firebase Dynamic Links in other projects before using the page.link URL prefix (the only option at the time). However that no longer appears to be an option when e

6条回答
  •  攒了一身酷
    2021-02-05 02:09

    If you are getting this error with subdomain, this solution worked for me:

    {
      "hosting": [
        {
          "target": "app",
          "public": "build",
          "ignore": [
            "firebase.json",
            "**/.*",
            "**/node_modules/**"
          ],
          "appAssociation": "AUTO",
          "rewrites": [
            {
              "source": "/**",
              "destination": "/index.html"
            }
          ]
        },
        {
          "target": "links",
          "public": "build",
          "ignore": [
            "**"
          ],
          "appAssociation": "AUTO",
          "redirects": [
            {
              "source": "/",
              "destination": "{{your domain}}",
              "type": 302
            }
          ],
          "rewrites": [
            {
              "source": "/**",
              "dynamicLinks": true
            }
          ]
        },
        {
          "target": "invite",
          "public": "build",
          "ignore": [
            "**"
          ],
          "redirects": [
            {
              "source": "/",
              "destination": "{{your domain}}",
              "type": 302
            }
          ],
          "appAssociation": "AUTO",
          "rewrites": [
            {
              "source": "/**",
              "dynamicLinks": true
            }
          ]
        }
      ]
    }
    

提交回复
热议问题