We put some small updates out this afternoon to embedded timelines, and widgets-js in general.
Tweet Limit feature for embedded Timelines
You can now add an attribute to your embedded timeline code,
data-tweet-limit=“5” (between 1 and 20) that will render your timeline as a fixed, static set of Tweets, autosized to the content, with no scrollbars.
noscrollbar option to timeline chrome settings for regular scrolling timelines
You can now add
noscrollbar as a value to the
data-chrome settings of your widget which will hide the scrollbar in all browsers, where a scrollbar would ordinarily be visible. A lot of you have been asking for this feature, so we’ve added the option. I do urge you to consider the accessibility implications of hiding standard UI from users though, and where it’s appropriate in the context of your site or application.
twttr.widgets.load() can now be called with an array of target elements
twttr.widgets.load() function would either search the entire page body, or just a single root node when initializing lazy-loaded widgets in your page. You can now pass an array of
HTMLElement objects to the function, which should enable developers to pursue even more efficient and performant content loading (for example, all Tweet Embeds found within a provided array of root elements will be fetched in a single HTTP request.)
The following documentation pages have been updated with more detail about the new features: