Published
Edited
Aug 25, 2021
Fork of Tweet
Insert cell
Insert cell
tweet("993222403663675392")
Insert cell
Insert cell
function tweet(id, options) {
const div = document.createElement("DIV");
Promise.resolve().then(() => twttr.widgets.createTweet(id, div, options));
return div;
}
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
function timeline(username, options) {
options = options || {
width: width / 2,
height: width / 2,
dnt: true,
}
const div = document.createElement("DIV");
Promise.resolve().then(() => twttr.widgets.createTimeline({
sourceType: "profile",
screenName: username
}, div, options));
return div;
}
Insert cell
Insert cell
Insert cell
twttr = require("https://platform.twitter.com/widgets.js").catch(() => window.twttr)
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more