JSFiddle - React, Tailwind, and code Playground
skuska rozsirenia jQuery http://www.sitepoint.com/forums/showthread.php?597712-jQuery-Slide-Left-to-Right&s=a1a69c6147c3599c896f89ef229fb6b0&p=4140098&viewfull=1#post4140098
by lalatino
HTML
<div class="toggleWidth">togglewidth</div>
<div id="homeTown">hometown</div>
CSS
#homeTown{
background-color:blue;
}
JavaScript
$(document).ready(function() {
jQuery.fn.extend({
slideRight: function() {
return this.each(function() {
jQuery(this).animate({
width: 'show'
});
});
},
slideLeft: function() {
return this.each(function() {
jQuery(this).animate({
width: 'hide'
});
});
},
slideToggleWidth: function() {
return this.each(function() {
var el = jQuery(this);
if (el.css('display') == 'none') {
el.slideRight();
} else {
el.slideLeft();
}
});
}
});
jQuery('.toggleWidth').click(function() {
//alert('here');
jQuery('#homeTown').slideToggleWidth();
});
});