how to make input type date supported on all browsers

JavaScript
if ( $('[type="date"]').prop('type') != 'date' ) {
    $('[type="date"]').datepicker();
}
Source

Also in JavaScript: