Skip to content

Latest commit

 

History

History
33 lines (23 loc) · 902 Bytes

README.md

File metadata and controls

33 lines (23 loc) · 902 Bytes

AppDelegate-Firebase

Example of using Firebase PushMessages in iOS

Instruction

  1. Add these pods to your project
pod 'Firebase/Core'
pod 'Firebase/Messaging'
  1. Add GoogleService-Info.plist file to your project

  2. Copy AppDelegate+Firebase.swift file to your project

  3. Add next code to your AppDelegate didFinishLaunchingWithOptions method:

initNotifications(application: application)
  1. Add fcm token handling (storage / sending / etc) logic into didReceiveRegistrationToken method

  2. And add this method to your AppDelegate file:

internal func openNotification(userData: PushNotification) {

    // Push handling here
}

Example of AppDelegate