Skip to content

Example of using Google Sign-In for iOS, SwiftUI, Combine, Swift Concurrency, YTLiveStreaming framework, Swift package manager

License

Notifications You must be signed in to change notification settings

SKrotkih/LiveEvents

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

82 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

[ci]

LiveEvents

Your Youtube video manager.
It is an example of using YTLiveStreaming and SwiftGoogleSignIn Swift packages (SPM). It uses SwiftUI, Combine, New Swift Concurrency (await/async), Redux pattern for Swift.

Requirements

  • Xcode 13+
  • Swift 5.*

Introduction

  • First of all follow instructions for the YTLiveStreaming Framework and Package to create and set up Google application which uses the YouTube Data API v3.

  • Download or clone the repository

  • Launch console command pod install in the root directory

  • Open the LiveEvents.xcworkspace file in Xcode

  • Update current bundle id on yours

  • Rename Config.plist.example.plist (you can find it in the root directory) to Config.plist. Include it into the app main bundle. It used by SwiftGoogleSignIn package for Google signing in. Edit the Config.plist namely change client ID and API key values on yours

Config.plist

  • Open Info.plist and edit CFBundleURLSchemes key value. Change the value that starts with "com.googleusercontent.apps." based on your API key. It should be set to the reversed API key. The API key has the format XXXXXXXX.apps.googleusercontent.com and the allowed URL should be com.googleusercontent.apps.XXXXXXXX :

Info.plist Example

SwiftUI and Combine

UI of the app is developed with using SwiftUI and Combine frameworks and newest Concurrency Swift approach.

The Redux pattern

The app uses Redux pattern. In current version it's used for Sign In only. Please pay attention on the Home and SignIn screens.

Libraries Used

Video

LiveEvents Demo Video

The 'UIKit' of the app version

Branch 'UIKit' consists UIKit version of the app.

OSLog. Reading logs with the Console.app

  • Start the Console.app
  • Select your device (or simulator) in the Devices menu
  • Set up SUBSYSTEM and CATEGORY appstate in the search field
  • Save search pattern

Author Serhii Krotkykh

Changes history:

  • 20-12-2022 Update according 0.2.29 YTLeaveStreaming package build requarements, update mock data
  • 19-12-2022 Update according of the 0.2.28 YTLeaveStreaming package build
  • 30-11-2022 update with SwiftGoogleSignIn 1.57 build
  • 20-11-2022 current user session is safe now
  • 20-09-2022 bug fixes. Redesign home and log in screens
  • 20-07-2022 implement Redux pattern for Login scene
  • 15-07-2022 added CI unit tests with Xcode Actions
  • 11-11-2016 the project was created

About

Example of using Google Sign-In for iOS, SwiftUI, Combine, Swift Concurrency, YTLiveStreaming framework, Swift package manager

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published