When Does Twitter Fetch Card Meta Data?


#1

Hello, I have a card approved site that leverages the HTML history API and makes heavy use of javascript to switch between pages/posts. There is no traditional page refresh anywhere in the process, except for in older browsers.

Here is the problem. It seems like on the initial site load Twitter grabs the meta data once and stores that. The user can then navigate a few posts/pages away and then use the tweet button widget to share the content. The card that is shared with that tweet is always the meta data that lived on the first page loaded, unless you manually refresh the page and use the tweet button again. We are updating the meta information every time a user navigates to a new page and the information for the tweet button content itself, which is updated page to page correctly.

Is there a way to tell Twitter to re-evaluate the meta information in the head without a page refresh? Maybe something similar to reloading the tweet button widget with twttr.widgets.load?


#2

Hi, wanted to update this with my solution.

Initially with our tweet button we did not include the data-url parameter and we relied on the widget to pull the URL of the page it was on. This worked consistently until we implemented cards on the site. Adding the URL fetches the correct card data now when the tweet button is used from any page.