diff --git a/js/application.js b/js/application.js index 359117a4687..9de6d0ff2d9 100644 --- a/js/application.js +++ b/js/application.js @@ -85,6 +85,8 @@ $(function(){ var moveItemSlider = function () { var activeItem = $(".js-item-slider--wrapper .js-item.js-active"); + if (activeItem.empty()) return; + var activeItemPosition = activeItem.position(); var activeItemOffset = activeItemPosition.left; var activeItemWidth = activeItem.outerWidth(); @@ -105,6 +107,8 @@ $(function(){ $(this).siblings().removeClass("js-active"); moveItemSlider(); }); + + new Spring.ProjectDocumentationWidget(); });