Hi all, i faced an issue with the plugin and struggle for 3 days. As you can read in the title, i use lazy loading in my ionic 3 project and that is why i end up in such issue. So i want to share how i solved it to spare you headache.
As you noticed, adding CUSTOM_ELEMENTS_SCHEMA, NO_ERRORS_SCHEMA to the module schemas array did not help.
you should add IonicAudioModule to the module of the page where you're using the audio-track tag
this is my project pages structures:
home.ts home.html home.scss home.module.ts
so in the home.module.ts, i simply added IonicAudioModule to the imports array just like the following code sample:
`import { NgModule } from '@angular/core';
import { IonicPageModule } from 'ionic-angular';
import { HomePage } from './home';
import { IonicAudioModule } from 'ionic-audio';
Hi all, i faced an issue with the plugin and struggle for 3 days. As you can read in the title, i use lazy loading in my ionic 3 project and that is why i end up in such issue. So i want to share how i solved it to spare you headache.
As you noticed, adding CUSTOM_ELEMENTS_SCHEMA, NO_ERRORS_SCHEMA to the module schemas array did not help.
you should add
IonicAudioModule
to the module of the page where you're using the audio-track tagthis is my project pages structures:
home.ts home.html home.scss home.module.ts
so in the
home.module.ts
, i simply addedIonicAudioModule
to theimports
array just like the following code sample:`import { NgModule } from '@angular/core'; import { IonicPageModule } from 'ionic-angular'; import { HomePage } from './home'; import { IonicAudioModule } from 'ionic-audio';
@NgModule({ declarations: [ HomePage, ], imports: [ IonicPageModule.forChild(HomePage), IonicAudioModule ] }) export class HomePageModule {} `
I do hope it helps
my `ionic info
ionic 3.9.2 angular 5.0.3 `
@arielfaur, please consider updating the README page
thanks for your job