hexagon.print.css
.
It can be included on any page using the following: <link rel="stylesheet" href="path_to_hexagon/hexagon.print.css" media="print">
<script src="path_to_hexagon/hexagon.print.js"></script>
onbeforeprint
and onafterprint
that iterates over all the link elements on the page and creates a 'citation' for each link, as well as an element at the end of the document listing all the links. <a class="hx-btn" href="https://hexagonks.io">Link to hexagonjs.io</a>
<a class="hx-btn" href="https://hexagonjs.io/">Link to hexagonjs.io<sup class="hx-footnote-ref hx-print-only">[1]</sup></a>
<div class="hx-footnote-links hx-print-only">
<hr>
<h2>Links</h2>
<ol>
<li>https://hexagonjs.io/</li>
</ol>
</div>