3

I'm on angular material 9.2.0. I installed @angular-material-components/datetime-picker for dateTimePicker .

I get this errors when I run ng build --prod.

enter image description here

5
  • Does it work if you change the import to import {MatDatePickerModule} from '@angular/material/datepicker'; instead of importing DateRange? Typically you need to import the entire module, and this is the correct one inside the Material Docs Commented Jul 9, 2020 at 14:47
  • stackblitz.com/edit/… Commented Jul 9, 2020 at 14:53
  • Thank you @JeremyLucas for your response, no doesn't work Commented Jul 9, 2020 at 14:57
  • Try manually deleting your node_modules folder, package-lock.json , and then restarting your code editor, typing npm install and trying again Commented Jul 9, 2020 at 15:00
  • 1
    @AsakkourSoufiane thanks, struggling with this for half an hour now :D Commented Jul 10, 2020 at 8:47

1 Answer 1

17

I found a solution for that on github, The latest version 4.x.x supports Angular 10. For Angular 9, you should use the version 2.x by using this command:

npm i @angular-material-components/[email protected] --save

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.