I'm trying to use the library in IONIC 5. Follow the installation step by step but when trying to use some feature modules (e.g. FivGalleryModule) into a Page the following error appears:
core.js:38781 Angular is running in the development mode. Call enableProdMode() to enable the production mode.
common.js:290 Native: tried calling StatusBar.styleDefault, but Cordova is not available. Make sure to include cordova.js or run in a device/simulator
cordovaWarn @ common.js:290
checkAvailability @ common.js:146
callCordovaPlugin @ common.js:232
(anonymous) @ common.js:315
cordova @ cordova.js:3
push../node_modules/@ionic-native/status-bar/ngx/index.js.StatusBar.styleDefault @ index.js:10
(anonymous) @ app.component.ts:22
invoke @ zone-evergreen.js:359
onInvoke @ core.js:39699
invoke @ zone-evergreen.js:358
run @ zone-evergreen.js:124
(anonymous) @ zone-evergreen.js:855
invokeTask @ zone-evergreen.js:391
onInvokeTask @ core.js:39680
invokeTask @ zone-evergreen.js:390
runTask @ zone-evergreen.js:168
drainMicroTaskQueue @ zone-evergreen.js:559
Promise.then (async)
scheduleMicroTask @ zone-evergreen.js:542
scheduleTask @ zone-evergreen.js:381
scheduleTask @ zone-evergreen.js:211
scheduleMicroTask @ zone-evergreen.js:231
scheduleResolveOrReject @ zone-evergreen.js:845
then @ zone-evergreen.js:955
bootstrapModule @ core.js:40600
./src/main.ts @ main.ts:11
__webpack_require__ @ bootstrap:83
0 @ main.ts:12
__webpack_require__ @ bootstrap:83
checkDeferredModules @ bootstrap:44
webpackJsonpCallback @ bootstrap:31
(anonymous) @ main.js:1
common.js:290 Native: tried calling SplashScreen.hide, but Cordova is not available. Make sure to include cordova.js or run in a device/simulator
cordovaWarn @ common.js:290
checkAvailability @ common.js:146
callCordovaPlugin @ common.js:232
(anonymous) @ common.js:315
cordova @ cordova.js:3
push../node_modules/@ionic-native/splash-screen/ngx/index.js.SplashScreen.hide @ index.js:10
(anonymous) @ app.component.ts:23
invoke @ zone-evergreen.js:359
onInvoke @ core.js:39699
invoke @ zone-evergreen.js:358
run @ zone-evergreen.js:124
(anonymous) @ zone-evergreen.js:855
invokeTask @ zone-evergreen.js:391
onInvokeTask @ core.js:39680
invokeTask @ zone-evergreen.js:390
runTask @ zone-evergreen.js:168
drainMicroTaskQueue @ zone-evergreen.js:559
Promise.then (async)
scheduleMicroTask @ zone-evergreen.js:542
scheduleTask @ zone-evergreen.js:381
scheduleTask @ zone-evergreen.js:211
scheduleMicroTask @ zone-evergreen.js:231
scheduleResolveOrReject @ zone-evergreen.js:845
then @ zone-evergreen.js:955
bootstrapModule @ core.js:40600
./src/main.ts @ main.ts:11
__webpack_require__ @ bootstrap:83
0 @ main.ts:12
__webpack_require__ @ bootstrap:83
checkDeferredModules @ bootstrap:44
webpackJsonpCallback @ bootstrap:31
(anonymous) @ main.js:1
core.js:6014 ERROR Error: Uncaught (in promise): Error: Template parse errors:
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@20:29 ("
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="[ERROR ->]#gallery.close()">
<ion-icon slot="icon-only" name="close"></ion-icon>
</ion-button"): ng:///HomePageModule/HomePage.html@20:29
Empty expressions are not allowed ("
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="[ERROR ->]#gallery.close()">
<ion-icon slot="icon-only" name="close"></ion-icon>
</ion-button"): ng:///HomePageModule/HomePage.html@20:29
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@20:29 ("
</ion-toolbar>
</fiv-gallery-toolbar>
<fiv-gallery-image [src]="[ERROR ->]image"></fiv-gallery-image>
</fiv-gallery>
"): ng:///HomePageModule/HomePage.html@26:28
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@20:29 ("
</fiv-gallery>
[ERROR ->]<fiv-gallery #gallery>
<fiv-gallery-image [src]="image"></fiv-gallery-image>
<fiv-gallery-toolbar"): ng:///HomePageModule/HomePage.html@29:0, Directive FivGallery
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@20:29 ("
<fiv-gallery #gallery>
<fiv-gallery-image [src]="[ERROR ->]image"></fiv-gallery-image>
<fiv-gallery-toolbar position="bottom">
<ion-toolbar color="transpa"): ng:///HomePageModule/HomePage.html@30:28
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@20:29 ("
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="[ERROR ->]gallery.close()">
Close
</ion-button>
"): ng:///HomePageModule/HomePage.html@34:29
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@20:29 ("
</fiv-gallery>
[ERROR ->]<fiv-gallery #gallery>
<fiv-gallery-toolbar position="top">
<ion-toolbar color="transparent">
"): ng:///HomePageModule/HomePage.html@42:0, Directive FivGallery
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@20:29 ("
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="[ERROR ->]#gallery.close()">
<ion-icon slot="icon-only" name="close"></ion-icon>
</ion-button"): ng:///HomePageModule/HomePage.html@46:29
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@46:29 ("
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="[ERROR ->]#gallery.close()">
<ion-icon slot="icon-only" name="close"></ion-icon>
</ion-button"): ng:///HomePageModule/HomePage.html@46:29
Empty expressions are not allowed ("
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="[ERROR ->]#gallery.close()">
<ion-icon slot="icon-only" name="close"></ion-icon>
</ion-button"): ng:///HomePageModule/HomePage.html@46:29
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@20:29 ("
</ion-toolbar>
</fiv-gallery-toolbar>
<fiv-gallery-image [src]="[ERROR ->]image"></fiv-gallery-image>
<fiv-gallery-toolbar position="bottom">
<ion-toolbar color="transpa"): ng:///HomePageModule/HomePage.html@52:28
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@46:29 ("
</ion-toolbar>
</fiv-gallery-toolbar>
<fiv-gallery-image [src]="[ERROR ->]image"></fiv-gallery-image>
<fiv-gallery-toolbar position="bottom">
<ion-toolbar color="transpa"): ng:///HomePageModule/HomePage.html@52:28
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@20:29 ("
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="[ERROR ->]gallery.close()">
Close
</ion-button>
"): ng:///HomePageModule/HomePage.html@56:29
Parser Error: Unexpected token # at column 1 in [#gallery.close()] in ng:///HomePageModule/HomePage.html@46:29 ("
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="[ERROR ->]gallery.close()">
Close
</ion-button>
"): ng:///HomePageModule/HomePage.html@56:29
Reference "#gallery" is defined several times ("
</fiv-gallery>
<fiv-gallery [ERROR ->]#gallery>
<fiv-gallery-toolbar-content></fiv-gallery-toolbar-content>
<fiv-gallery-image [src]="i"): ng:///HomePageModule/HomePage.html@4:13
Reference "#gallery" is defined several times ("
</fiv-gallery>
<fiv-gallery [ERROR ->]#gallery>
<fiv-gallery-toolbar position="top">
<!-- ancompiler.js:2175)
at TemplateParser.parse (compiler.js:11388)
at JitCompiler._parseTemplate (compiler.js:25963)
at JitCompiler._compileTemplate (compiler.js:25951)
at compiler.js:25895
at Set.forEach (<anonymous>)
at JitCompiler._compileComponents (compiler.js:25895)
at compiler.js:25808
at Object.then (compiler.js:2166)
at JitCompiler._compileModuleAndComponents (compiler.js:25807)
at resolvePromise (zone-evergreen.js:797)
at resolvePromise (zone-evergreen.js:754)
at zone-evergreen.js:858
at ZoneDelegate.invokeTask (zone-evergreen.js:391)
at Object.onInvokeTask (core.js:39680)
at ZoneDelegate.invokeTask (zone-evergreen.js:390)
at Zone.runTask (zone-evergreen.js:168)
at drainMicroTaskQueue (zone-evergreen.js:559)
import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { RouteReuseStrategy } from '@angular/router';
import { IonicModule, IonicRouteStrategy } from '@ionic/angular';
import { SplashScreen } from '@ionic-native/splash-screen/ngx';
import { StatusBar } from '@ionic-native/status-bar/ngx';
import { AppComponent } from './app.component';
import { AppRoutingModule } from './app-routing.module';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
@NgModule({
declarations: [AppComponent],
entryComponents: [],
imports: [BrowserModule, IonicModule.forRoot(), AppRoutingModule, BrowserAnimationsModule],
providers: [
StatusBar,
SplashScreen,
{ provide: RouteReuseStrategy, useClass: IonicRouteStrategy }
],
bootstrap: [AppComponent]
})
export class AppModule {}
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { IonicModule } from '@ionic/angular';
import { FormsModule } from '@angular/forms';
import { HomePage } from './home.page';
import { HomePageRoutingModule } from './home-routing.module';
import { FivGalleryModule } from '@fivethree/core';
@NgModule({
imports: [
CommonModule,
FormsModule,
IonicModule,
HomePageRoutingModule,
FivGalleryModule,
],
declarations: [HomePage]
})
export class HomePageModule {}
<fiv-gallery #gallery>
<fiv-gallery-image [src]="image"></fiv-gallery-image>
</fiv-gallery>
<fiv-gallery #gallery>
<fiv-gallery-toolbar-content></fiv-gallery-toolbar-content>
<fiv-gallery-image [src]="image"></fiv-gallery-image>
</fiv-gallery>
<fiv-gallery #gallery>
<fiv-gallery-toolbar position="top">
<!-- any custom content -->
</fiv-gallery-toolbar>
<fiv-gallery-image [src]="image"></fiv-gallery-image>
</fiv-gallery>
<fiv-gallery #gallery>
<fiv-gallery-toolbar position="top">
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="#gallery.close()">
<ion-icon slot="icon-only" name="close"></ion-icon>
</ion-button>
</ion-buttons>
</ion-toolbar>
</fiv-gallery-toolbar>
<fiv-gallery-image [src]="image"></fiv-gallery-image>
</fiv-gallery>
<fiv-gallery #gallery>
<fiv-gallery-image [src]="image"></fiv-gallery-image>
<fiv-gallery-toolbar position="bottom">
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="gallery.close()">
Close
</ion-button>
</ion-buttons>
</ion-toolbar>
</fiv-gallery-toolbar>
</fiv-gallery>
<fiv-gallery #gallery>
<fiv-gallery-toolbar position="top">
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="#gallery.close()">
<ion-icon slot="icon-only" name="close"></ion-icon>
</ion-button>
</ion-buttons>
</ion-toolbar>
</fiv-gallery-toolbar>
<fiv-gallery-image [src]="image"></fiv-gallery-image>
<fiv-gallery-toolbar position="bottom">
<ion-toolbar color="transparent">
<ion-buttons slot="end">
<ion-button (click)="gallery.close()">
Close
</ion-button>
</ion-buttons>
</ion-toolbar>
</fiv-gallery-toolbar>
</fiv-gallery>e