title: RxSwift Simple background task example
body: <p>I have a method as following</p>
  
  <pre><code>public static func createAlbum(named: String, completion: (album: PHAssetCollection?) -&gt; ()) {
          dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_BACKGROUND, 0)) {
  
        }) { success, error in
  
  
                  completion(album: album)
            }
         }
  }
  </code></pre>
  
  <p>How can i do the background task using RxSwift</p>
  
  <p>complete code</p>
  
  <p><a href="https://gist.github.com/sazzadislam-dsi/d347909d284674c936e397ac423703cf" rel="nofollow noreferrer">https://gist.github.com/sazzadislam-dsi/d347909d284674c936e397ac423703cf</a></p>