A simple script to populate a web page with links, retrieving link info using the Open Graph protocol (https://ogp.me).
I am using https://getbootstrap.com for the grid system.
I built it for my personal page: https://danilop.net
-
Put static assets in the
static
folder. -
Put HTML templates with
<!-- processLinks {JSON file} {thumbnail width} {title width} [max links] -->
where you want to embed links in thesrc
folder. The thumbnail and title width are using the https://getbootstrap.com grid system and should add to 12. You can optionally add a maimum number of links to process from the source list. -
The JSON file should be in the
data
folder and contain a single JSON array of links. -
Run
npm run build
to create thepublic
folder. I use AWS Amplify Console to automate deployment. -
Using the Open Graph protocol, this is getting all the info (title, thumbnail) from the link source, such as Speaker Deck or YouTube.