Change datepicker display format

datepicker
angular js

In Angular js the bs-datepicker date format will be changed by adding below filter into your js file.

angular.module('test')
.config(function($datepickerProvider) {
  angular.extend($datepickerProvider.defaults, {
    dateFormat: 'MM-dd-yyyy',
    startWeek: 1
  });
});

 

You might also like:

Detect AdBlock with JavaScript in my browser

30-07-2017 AdBlock javascript detect

Get previous date from given date in javascript

06-03-2017 date javascript previous date

Get next date from given date in javascript

06-03-2017 date javascript next date

Filter for replace text in Angular Js

05-03-2017 filter replace angular js

Get random strings from given string In javascript

21-02-2017 javascript random string