Please remember, the issues forum is __NOT__ for support requests. It is for bugs and feature requests only.
Please read https://github.com/ng-bootstrap/ng-bootstrap/blob/master/CONTRIBUTING.md and search
existing issues (both open and closed) prior to opening any new issue and ensure you follow the instructions therein.
Uncompatible with typescript strict null checks Support. The parse method should return null or NgbDateStruct. Right now return only NgbDateStruct.
You can fork a plunker from one of our demos and use it as a starting point.
Please note that we can _not_ act on bug reports without a minimal reproduction scenario in plunker. Here is why:
https://github.com/ng-bootstrap/ng-bootstrap#you-think-youve-found-a-bug
Angular: 4
ng-bootstrap:
Bootstrap:
For someone who has this issue but want to use strict null checks the workaround is to add any before null
if (!value) {
return <any>null;
}
return d.isValid() ? { year: d.year(),
month: d.month() + 1,
day: d.date() } : <any>null;
Not beautiful but works :-)
Yeh, we should review this project for the proper strict null checks...
So I took a stab at trying to implement proper strict null checks...this is not an easy task. This pollutes a lot of areas, and needs a lot of love.
Most helpful comment
Yeh, we should review this project for the proper strict null checks...