3 ms·
Show HN: Hovercard.js, simple hovercard utility for web pages
One of my favourite features of Wikipedia is the hovercard. You can hover over a link and see a preview of the content at the link destination.
I made a small JavaScript utility that accepts a JSON object with link information and enables hovercards on a personal website. I am "eating what I cook" per se by running this on my website. You can hover over any link in blog posts on my personal website and see hovercard.js in action.
Here's an example:
https://jamesg.blog/2023/05/19/airport-pianos/
I also maintain a Python package [1] that makes it easy to retrieve meta information about sites for use with hovercards [1] (The format is title, image, and description, so you can use any tool you want, though!).
[1] https://jamesg.blog/2022/10/12/hovercards/ https://jamesg.blog/2022/10/12/hovercards/
- jqpabc123 3y agoHow do you "hover" on a touch screen?