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

c++ - llvm function pass ReplaceInstWithInst malloc -

java.lang.NoClassDefFoundError When Creating New Android Project -

Decoding a Python 2 `tempfile` with python-future -