Ionic4 - Youtube videos INSIDE the app

Is it possible to play youtube videos full screen in the app? If so, is it possible to know when the video ends and then execute code?

I’m trying to build a workout app that allows the user to pick exercises. It would then play a private YouTube video for each exercise and when the video ends, it would display a countdown timer (cooldown) and then go on to the next video.

I tried the youtubeplayer cordova plugin but it seems to pass execution to the youtube app and then doesn’t return to my app.

Any ideas on how to accomplish this?

I believe you can use iframe this way:

<iframe src="http://player.vimeo.com/video/VIDEO-ID-HERE" width="WIDTH" height="HEIGHT" frameborder="0" webkitallowfullscreen mozallowfullscreen allowfullscreen></iframe>

Reference