function renderNavTree()

in scripts/docsite.js [90:107]


function renderNavTree() {
    var navRootUl = document.getElementById('nav-root-ul');
    if (!navRootUl) {
        // The "nav-root-ul" element doesn't exist, so use Jekyll navigation instead
        return;
    }
    console.log('Loading navigation');
    fetch('/assets/nav_api.json')
        .then(function (response) {
        return response.json();
    })
        .then(function (jsonNodes) {
        var currentPageUrl = getUrlForComparison(document.location.pathname);
        renderNavNodes(rootNodes, jsonNodes, navRootUl, undefined, currentPageUrl);
    })["catch"](function (e) {
        console.log('ERROR: Failed to fetch navigation: ' + e.toString());
    });
}