heliomarpm / ion-calendar

📅 A date picker component for ionic6+
https://ioncalendar-demo.web.app/
MIT License
2 stars 1 forks source link

Module Import Not Working #4

Open vicatcu opened 2 months ago

vicatcu commented 2 months ago

Describe the bug

At compile time I get the following errors in VSCode:

Value at position 6 in the NgModule.imports of AppModule is not a reference Value could not be determined statically.(-991010) app.module.ts(28, 5): Unable to evaluate this expression statically. app.module.ts(28, 5): A value for 'forRoot' cannot be determined statically, as it is an external declaration.

To Reproduce

As described in the Change Defaults usage example in the README

Code snippet

...
import { CalendarModule } from 'ion7-calendar';
...
@NgModule({
  declarations: [AppComponent],
  imports: [
    ...
    CalendarModule.forRoot({closeIcon: true}),
    ...
  ],
  providers: [{ provide: RouteReuseStrategy, useClass: IonicRouteStrategy }],
  bootstrap: [AppComponent],
})
export class AppModule {}
...

Expected behavior

As described in the Change Defaults usage example in the README, this should build without error.

Node.js Version

18.20.2

OS

Linux 6.9

Additional Library Versions

Ionic:

   Ionic CLI                     : 7.2.0
   Ionic Framework               : @ionic/angular 7.8.6
   @angular-devkit/build-angular : 16.2.9
   @angular-devkit/schematics    : 16.2.9
   @angular/cli                  : 16.2.14
   @ionic/angular-toolkit        : not installed

Capacitor:

   Capacitor CLI      : 5.7.5
   @capacitor/android : 5.7.8 
   @capacitor/core    : 5.7.8
   @capacitor/ios     : 5.7.8 

Utility:

   cordova-res : not installed globally
   native-run  : 2.0.1

System:

   NodeJS : v18.20.2 
   npm    : 10.5.0
   OS     : Linux 6.9

Additional context/Screenshots

No response

heliomarpm commented 2 months ago

Which library are you using in your project? This is the package @heliomarpm/ion-calendar in your code snippet you are using ion7-calendar

vicatcu commented 2 months ago

Both repos have the same issue, I cut and paste code from the other one

heliomarpm commented 2 months ago

Ambos os repositórios têm o mesmo problema, eu recorto e colo o código do outro

I'm unable to reproduce this error, can you provide a demonstration repository?