css - Change table class in mobile view? -


i using bootstrap , table have table-condensed class applied in mobile view, , table-responsive class applied above mobile size.

what best approach that? there way in sass?

i have stumbled across 'extend' in sass don't think quite need when tried implement it, couldn't use within media query, outside of media query worked ok

thank :)

(i working on trying include code getting error)

you can use jquery resize function

example

$( window ).resize(function() {  var screenwidth = $(document).width();  if(screewidth <= 480)  {   $("#table").removeclass("table-responsive");   $("#table").addclass("table-condensed");  }  else  {   $("#table").removeclass("table-condensed");   $("#table").addclass("table-responsive");  } }); 

Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

ruby on rails - Seeing duplicate requests handled with Unicorn -