Email or username:

Password:

Forgot your password?
Top-level
Terence Eden

Spite-Driven-Development continues.

I now have a scrap of semantic HTML which adequately replicates an embedded Tweet.

TODO:

* Add images
* Add entities (hashtags, mentions, links)
* Add parent of thread
* Add quoted tweet
* Add ... whatever else

Should be able to hijack the embed API to get most metadata (no number or replies / retweets though).

3 comments
Terence Eden

Parents and Quotes are just <blockquotes> within <blockquotes>. So that was easy!

Terence Eden

I think that's good enough for the basics.

This code will (eventually) convert all your embedded Tweets into proper semantic HTML without any tracking back to Twitter.

Rough code at:
github.com/edent/Tweet2Embed

Terence Eden

OK gang! This is ready for you to test.

python tweet2html.py --css 1234

That will take a Twitter ID and return HTML and CSS for you to embed in your website with no calling back to Twitter.

Features:
🗣 Avatars inlined as Base64 WebP
📸 All attached photos inlined
🎥 Video poster inline, <video> to original source
🔗 Hyperlinks don't use t.co
#️⃣ Hashtags and @ mentions linked
🕰 Semantic time
♥ and 🗨 counts

Try it out at github.com/edent/Tweet2Embed

Feedback and pull requests very welcome!

OK gang! This is ready for you to test.

python tweet2html.py --css 1234

That will take a Twitter ID and return HTML and CSS for you to embed in your website with no calling back to Twitter.

Features:
🗣 Avatars inlined as Base64 WebP
📸 All attached photos inlined
🎥 Video poster inline, <video> to original source
🔗 Hyperlinks don't use t.co
#️⃣ Hashtags and @ mentions linked
🕰 Semantic time
♥ and 🗨 counts

Go Up