Ionic 2: what is <ion-overlay>?


Tried the modal and got this error message:

< ion-overlay > < /ion-overlay > required in root component template to use: modal

I know the modal works because if I take the code from drifty github, it works.

I copied the code that calls the modal and the modal from the Github example and integrated to my app and got the same error.

Maybe, by understanding what it does mean, it will help me to figure out the cause.

Thanks in advance!

1 Like

Finally found why the modal was not showing!!!

Need to add in your app.html. Just after your !!

yeh! :smile:

Yes, the ion-overlay component is required for Modals and Popups in v2. We have an open issue to remove this requirement. :smile:

Sorry for the inconvenience! We have added the ion-overlay to the starters.