FlexSlider
FlexSlider copied to clipboard
Maximum call stack exceeded when adding a slide
I have FlexSlider 2.5 installed in my shopify theme and whenever I try to add a slide I get this error
Uncaught RangeError: Maximum call stack size exceeded
Here's the code I use to add a slide:
$('.product_slider').data('flexslider').addSlide($(li_html));
Here's the code I instantiate the flexslider with
$('.product_slider').flexslider({
startAt: parseInt($('.featured_image', $(this)).data('index'), 10),
touch: true,
pauseOnHover: true,
controlNav: "thumbnails",
directionNav: false,
{% if settings.product_slideshow_animation == 'none' or settings.product_slideshow_animation == 'zoom' %}
slideshow: false,
{% else %}
animation: "{{ settings.product_slideshow_animation }}",
{% endif %}
slideshowSpeed: {% if settings.slideshow_speed != blank %}{{ settings.slideshow_speed }}{% else %}10{% endif %}*1000,
animationSpeed: 1
});
I am not sure what's causing this error when adding a slide.
Edit: I also get the same error when I am trying to delete the file.
How many slides are you trying to add?
I have the same problem, add 1 or >1 slides and in any case throw the error. I managed to detect the problem and that is when I add this line { controlNav: "thumbnails", } in flexslider init. I need to use 'controlnav' with 'thumbnails' too but I do not know how to solve the problem.
I also have this problem. Is like jrealpe said, deleting { controlNav: "thumbnails" } from flexslider the error disapear.
I also have this problem, but i need the thumbnails for controlnav. Has anyone solved the problem?
Having this problem as well. slider.addSlide()
calls slider.update()
, which calls methods.controlNav.update()
, which calls slider.update()
, which calls methods.controlNav.update()
, etc...
I also have this problem. Has anyone solved the problem?