Integrate firebase into app

Hi, I need help. I purchased this template https://market.ionicframework.com/starters/buddy-social-2
and now i need to integrate firebase as the database instead of json. Can anyone help me ?

Thanks