Skip to content

Instantly share code, notes, and snippets.

@arinhouck
Created November 18, 2015 04:20
Show Gist options
  • Save arinhouck/152e613a6596e47a6a5a to your computer and use it in GitHub Desktop.
Save arinhouck/152e613a6596e47a6a5a to your computer and use it in GitHub Desktop.
Table view image placeholder for when waiting on API to load, makes it look like table is filled with "grey text boxes"
Set on viewDidLoad()
self.tableView.backgroundColor = UIColor(patternImage: UIImage(named: "empty-cell.png")!)
Where ever you call your table reload after API call add this line:
self.tableView.backgroundColor = UIColor.whiteColor()
Here is the empty cell image used as a background pattern I made:
http://s3.postimg.org/895ohr0c3/empty_cell.png
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment