Issue On Animating Div on Adding and Removing Animate Class
Can you please take a look at This Demo and let me know why I am not able to add the Animation to second click (Doesn't Matter Add or Update)in to the div
I am using Animate.css plugin and the codes work fine for each one at first but after adding the removeClass() both of animation not functioning
- <ol class="breadcrumb">
<li>Model: Economics <span id="data"> </span></li>
</ol>
<button id="add" type="button" class="btn btn-default">Add</button>
<button id="update" type="button" class="btn btn-default">Update</button>
<script>
$(function () {
$("#add").on("click", function () {
$('#data').html('Just Been Added');
$('#data').addClass('animated bounceInLeft');
$('#data').removeClass('animated bounceInLeft');
});
$("#update").on("click", function () {
$('#data').html('Just Been Updated');
$('#data').addClass('animated bounceInLeft');
$('#data').removeClass('animated bounceInLeft');
});
});
</script>
Thanks