fetrarij / ngx-daterangepicker-material

Pure Angular 2+ date range picker with material design theme, a demo here:
https://fetrarij.github.io/ngx-daterangepicker-material/
MIT License
246 stars 247 forks source link

ngx-daterangepicker-material compability with angular 15 #524

Open krutikapatil-bh opened 1 year ago

krutikapatil-bh commented 1 year ago

Is ngx-daterangepicker-material 6.0.4 version compatible with Angular 15

Exabait commented 1 year ago
Error: node_modules/ngx-daterangepicker-material/daterangepicker.component.d.ts:3:8 - error TS1259: Module '".../node_modules/dayjs/esm/index"' can only be default-imported using the 'allowSyntheticDefaultImports' flag
3 import dayjs, { Dayjs } from 'dayjs/esm';
         ~~~~~

  node_modules/dayjs/esm/index.d.ts:3:1
    3 export = dayjs;
      ~~~~~~~~~~~~~~~
    This module is declared with 'export =', and can only be used with a default import when using the 'allowSyntheticDefaultImports' flag.

I'm trying to migrate my Angular app to 15 and get this error after update ngx-daterangepicker-material to 6.0.4.

How can I fix this?

enlight3d commented 1 year ago

same here and I don't really want to enable allowSyntheticDefaultImports ...

deferenty commented 1 year ago

The same problem in Angular 16

Elmanderrr commented 8 months ago

for those who are dont care about allowSyntheticDefaultImports, you can just add it to the tsconfg complierOptions with true value