Slider not immediately loads the images?

There is a slider. When the page loads it displays all pictures(4 PCs). As soon as click on the other months I see a different slider, but for some reason uploaded only one picture and not all. If you scroll through the slider, then loaded everything. And so with all hidden sliders. if they go back after and re-click any slider then displays all pictures. Slider using slick. Site onhome.devshift.co.uk/.
The code that hide or show sliders.
$('.slider_btn').click(function(){ 
 //Step 1. Turn off all the sliders 
console.log('mark1');
 $('.slider_work').each(function(){ 
console.log('mark2');
 $(this).removeClass('active'); 
 }); 
 //Step 2. Get the category id and put it on the aydishnik slider 
 var slider_id = $(this).attr('id'); 

console.log(slider_id);

 slider_id = slider_id.replace("btn_", "#slider_"); 
 //Step 3. Turn the slider to the desired category 

console.log(slider_id);

 $(slider_id).addClass('active'); 
 //$('#slider_12').addClass('active'); 
 });


5afcfd6c1b354171520267.png
June 5th 19 at 21:40
1 answer
June 5th 19 at 21:42
Solution
You must have the slider on one class or ID hanging, or you change the class/ID during the switching of tabs. It is necessary to reinitialize by clicking on the tab
decided otherwise. instead display non and block(probably slick slider is not very behaved because of this) did opacity 1 or 0 opacity - ettie_Beer commented on June 5th 19 at 21:45

Find more questions by tags jQueryLayoutSlider