PageSourceSearch

https://davidstenbeck.com/assets/js/index.js

js davidstenbeck.com collected 2026-10-09 22:07:33 UTC 748 bytes, 29 lines download raw bytes

1/**
2 * Main JS file for Casper behaviours
3 */
4
5/*globals jQuery, document */
6(function ($) {
7    "use strict";
8
9    $(document).ready(function(){
10
11        $(".post-content").fitVids();
12        
13        // Calculates Reading Time
14        $('.post-content').readingTime({
15            readingTimeTarget: '.post-reading-time',
16            wordCountTarget: '.post-word-count',
17        });
18        
19        // Creates Captions from Alt tags
20        $(".post-content img").each(function() {
21            // Let's put a caption if there is one
22            if($(this).attr("alt"))
23              $(this).wrap('<figure class="image"></figure>')
24              .after('<figcaption>'+$(this).attr("alt")+'</figcaption>');
25        });
26        
27    });
28
29}(jQuery));

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.