I am using jquery / ajax to pass into a route two variables (from a slider), min and max. At this point I just want the values and while I can see them in the route(console) and in the params, passing them into view, they are empty.
I haven't run into this before.
Right now the route is this -
post '/dir_scan' do
p @min = params[:min]
p @max = params[:max]
slim :listing, :layout => (request.xhr? ? false : :layout)
listing is a partial, embedded in another view.
This is the view (using slim)
I checked docs, but didn't really find anything as to the cause. I did try using the locals hash with no change in the behavior. My thinking is that while I'm not returning anything yet to jquery, the route is hit and it should reload with the values. Any ideas?
Sinatra - values disappearing between route and view