[jquery] jQuery Datepicker onchange event issue

I am using bootstrap-datepicker and none of above solution worked for me. This answer helped me ..

bootstrap datepicker change date event doesnt fire up when manually editing dates or clearing date

Here is what I applied:

 $('.date-picker').datepicker({
     endDate: new Date(),
     autoclose: true,
 }).on('changeDate', function(ev){
        //my work here
    });

Hope this can help others.