In this post, we will see how to resolve Shiny slickR, don’t advance slide if input is empty
Question:I have a shiny app where I have a slick slideshow and inputs that are associated with each image. The user will put in their name and then guess the age of each person in the photo. Every time the user advances the slide with the arrow the inputs will also advance. The user must fill out the inputs for the rest of the app to work (rest of app not shown here). What I would like is that every time the arrow is clicked the app will check to see if the associated input is empty and if it is the slideshow will not advance and a little message will pop up. I have tried to work out solutions with shinyjs and shinyvalidate and shinyalert but I can’t come up with a solution.
shinyglideas recommended by ismireshregal. I simplified it but you can prevent the slide from advancing if it doesn’t meet a condition using the
next_conditionargument. See here for more information: https://juba.github.io/shinyglide/articles/b_conditionals.html.
If you have better answer, please add a comment about this, thank you!