{"size": 1321, "ext": "js", "max_stars_repo_path": "assets/js/documentation.js", "max_stars_repo_name": "modolanguage/www", "max_stars_repo_stars_event_min_datetime": "2017-08-28T14:09:13.000Z", "max_stars_repo_stars_event_max_datetime": "2017-08-29T15:44:00.000Z", "max_issues_repo_path": "assets/js/documentation.js", "max_issues_repo_name": "modolanguage/www", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "assets/js/documentation.js", "max_forks_repo_name": "modolanguage/www", "max_forks_repo_forks_event_min_datetime": "2017-08-28T14:11:44.000Z", "max_forks_repo_forks_event_max_datetime": "2020-03-26T03:06:30.000Z"}
{"max_stars_count": 4, "max_issues_count": null, "max_forks_count": 3, "avg_line_length": 28.7173913043, "max_line_length": 71, "alphanum_fraction": 0.5450416351}
$(document).ready(function () {
    initializePage();
});
function initializePage() {

    // Materialize Init.
    $(".scrollspy").scrollSpy({ "scrollOffset": 200 });
    $(".button-collapse").sideNav();

    checkScroll();

    $(window).scroll(function(){
        checkScroll();
    });

    $('#navbarFixed').css('transform', 'translateY(0px)');
    $('#navbarFixed').css('position', 'fixed');

}
function isScrolledIntoView(element) {
    var elementTop = element.getBoundingClientRect().top;
    var elementBottom = element.getBoundingClientRect().bottom;

    var isVisible = (elementTop
            <= (window.innerHeight - (window.innerHeight / 2))) 
            && (elementBottom >= (window.innerHeight / 2));

    return isVisible;
}
function checkScroll() {
    for (let i = 0; i < $(".wrapper > section").length; i++) {
        let element = $(".wrapper > section")[i];
        let linkerID = element.getAttribute("data-linker");
        let linker = ("#" + linkerID);

        if (isScrolledIntoView(element)) {
            if (!$(linker).hasClass("active")) {
                $(linker).click();
            }
        } else {
            if ($(linker).hasClass("active")) {
                $(linker).click();
            }
        }
    } // for (let i = 0; i < $('.wrapper > section').length - 1; i++) {
}