Datapicker Componet in Ionic2

Is there a datapicker picker component in ionic2, I tried to use the datepicker as given in the ionic docs here:

I did the following steps:

  1. Installed the datepicker cordova plugin: cordova plugin add cordova-plugin-datepicker

  2. Added the following code:

`import {DatePicker} from ‘ionic-native’;{
date: new Date(),
mode: ‘date’
date => console.log("Seleted date is: ", date),
err => console.log(“Error occurred while getting date:”, err)

I get the error as ‘Module DatePicker not found’. How to install and configure this datepicker plugin? Can I install it via npm? Please help.

the native datepicker doesn’t work on browser.

Try on device self, it should appear.

When I try to import Datepicker i get the error as ‘Module not found’.

import {DatePicker} from ‘ionic-native’ So where to find the datepicker module. Have done the installation correctly? Is there any documentation on installing it?

Ok got it! I need to add the ionic-native module, I added it using npm install ionic-native, Now the datepicker works!!

The datepicker is bit old fashioned doesn’t show up the material design one or the ios 9 version

It shows something like this:

Should I update any plugins here? I update cordova-android to 5.0.0 though.

I don’t think so, I have the same old fashioned design and I am sure to have all updated.

Thanks! for the clarification, helped me.