Skip to content

A social media based around finding people that like the same songs you enjoy.

License

Notifications You must be signed in to change notification settings

albertstartup/swaybeat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Swaybeat iOS

A social media based around finding people that like the same songs you enjoy.

Project Structure

  • The UI was mostly built programmaticly.

  • Integrates Spotify and Soundcloud API. Implements Spotify OAuth login.

  • Phone Number Based Signin

  • Usage of reactive programming to emulate React

// Swaybeat/SongSearchPage.swiftt

searchController.searchBar.rx_text
      .filter({text in
        if !text.isEmpty {
          return true
        } else {
          return false
        }
      })
      .debounce(0.75, scheduler: MainScheduler.instance)
      .subscribeNext {text in
        
        print("searching: \(text)")
        
        SPTSearch.performSearchWithQuery(...)
  • Custom URL audio player library.
// Swaybeat/GlobalPlayer/URLPLayer.swift

class URLPlayer: NSObject {
  private let player = AVPlayer()
  
  var isPlaying = false
  private(set) var didEnd = false
  private(set) var currentURL: NSURL?
  
  override init() {
    super.init()
    
    NSNotificationCenter.defaultCenter().addObserver(self, selector: "URLPlayerDidEnd:", name: AVPlayerItemDidPlayToEndTimeNotification, object: self)

    player.addObserver(self, forKeyPath: "rate", options: NSKeyValueObservingOptions([.New, .Initial]),context: nil)
  }
  
  func play(url: NSURL) {
  • Crashlytics

  • Alamofire

About

A social media based around finding people that like the same songs you enjoy.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published