ng2-datepicker + not supported in angular 4

angular, angular2-forms, datepicker

Solution

check your `package.json` and make sure you have this:

"@angular/core": "^4.0.1",
"@angular/forms": "^4.0.1",

That would mean that your migration to version 4 (at least on those modules) has been succesful.

And for datepicker, use `ng2-datetime`. Works like a charm.

For installing it:

npm install --save ng2-datetime

npm Docs: https://www.npmjs.com/package/ng2-datetime

github Docs: https://github.com/nkalinov/ng2-datetime

Documentation: https://nkalinov.github.io/ng2-datetime/

Problem

I am trying to upgrade from angular 2.4.0 to angular 4. When i tried it, i found following peer dependency errors: Tried installing latest datepicker: ``` npm install ng2-datepicker –save ``` Got following error: ``` npm WARN ng2-datepicker@1.8.3 requires a peer of @angular/forms@^2.4.0 but none was installed. ``` Tried installing latest tooltip: ``` npm install ngx-tooltip –save ``` Got following error: ``` npm WARN ngx-tooltip@0.0.9 requires a peer of @angular/core@^2.0.0 but none was installed. ``` How do i use ng2-datepicker/ngx-tooltip with angular 4? Or is there any other module for datepicker and tooltip which can work for angular 4.

Original source