5 ms·
- copy paste the content of the tweet - meta data is lost (date and time, author, obv it is possible to copy paste the text and add links to original tweet and
by polydevil 4y ago
- copy paste the content of the tweet - meta data is lost (date and time, author, obv it is possible to copy paste the text and add links to original tweet and link to an author;
- screenshot - now you dont have to add custom styles, meta data exists, but it is not usable - you can make is to click on tweet will open a tweet, but click on tweet author will open authors profile. Also screenreaders and bots - they dont parse text from images and it is harder to make images work on smaller screens.
The solution is not as simple as - ctrl+c ctrl+v text or screenshot and call it a day.
You need to consider that content will be interactive (all links should work) and accessible (for screenreaders and mobile).
___
So it is understandable why low effort approach with embedded scripts, but less secure is more popular than high effort most likely not completely working, but more secure approach.
The better way would be to use twitter api and render tweets with your own styles. Safe, accessible, interactive.
- hamilyon2 4y agoDo web browsers nowadays have a way to save a part of html dom with every style inlined? If not, that is a huge opportunity.
- macspoofing 4y agoI think that's an impossible problem to solve for the general case. To guarantee correct rendering, you very well need to push the site through the entire rendering/js pipeline.
- genidoi 4y agoSinglePage the chrome extension does this I believe
- cxr 4y ago<https://news.ycombinator.com/item?id=30527999 https://news.ycombinator.com/item?id=30527999> See also: <https://gildas-lormeau.github.io/ https://gildas-lormeau.github.io/>
- joeraut 4y agoGreat point on accessibility, a guarantee of screen reader support is a benefit that would be lost with screenshots or text without the correct semantics.
- macspoofing 4y agoWell .. you're going to have to do that because the alternative is that the tweet can be pulled from your article. >The better way would be to use twitter api and render tweets with your own styles. How does that fix the issue of twitter obfuscating embedded tweets?