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:

Convert and download html to pdf without saving file

28-10-2018 node js convert html to pdf pdf download pdf without saving

Functions in javascript

25-05-2018 functions javascript es5 es6 arrow functions named functions Closures Nested Functions Callbacks Arrow functions.

How to get current date and time (yyyy-mm-dd H:i:s) using javascript

09-03-2017 javascript date time

Filters for convert text to camel case in Angular Js

05-03-2017 angularjs camelcase filters

Send Mail in Node Js

21-02-2017 node js mail npm module