How to set dynamic Meta Tags and Open Graph tags in polymer?

后端 未结 2 1940
伪装坚强ぢ
伪装坚强ぢ 2021-01-04 22:30

I have a polymer node site that I\'ve been working on and can\'t figure out how to include dynamic meta tags and Open Graph tags. Jquery won\'t work and neither will using t

2条回答
  •  臣服心动
    2021-01-04 23:07

    If you host your Polymer app with Firebase, you can prerender the index.html file with a Firebase http trigger function.

    exports.host = functions.https.onRequest((req, res) => {
      // replace og-tags in the index.html file and return it
    });
    

    See this post for more info.

提交回复
热议问题