         }
     }
 }
+
+// MARK: UIEmptyState Data Source & Delegate
+
+extension ClassesTableViewController: UIEmptyStateDataSource, UIEmptyStateDelegate {
+    
+    // Empty State Data Source
+    
+    func shouldShowEmptyStateView(forTableView tableView: UITableView) -> Bool {
+        // If not items then empty, show empty state
+        return DatabaseManager.shared.realm.objects(Class.self).count == 0
+    }
+    
+    var emptyStateTitle: NSAttributedString {
+        let attrs: [NSAttributedStringKey: Any] = [.foregroundColor: UIColor.mainText,
+                                                   .font: UIFont.systemFont(ofSize: 20)]
+        return NSAttributedString(string: "No Classes Added", attributes: attrs)
+    }
+    
+    var emptyStateImage: UIImage? { return #imageLiteral(resourceName: "EmptyClassesIcon") }
+    
+    var emptyStateButtonTitle: NSAttributedString? {
+        let attrs: [NSAttributedStringKey: Any] = [.foregroundColor: UIColor.accentGreen,
+                                                   .font: UIFont.systemFont(ofSize: 18)]
+        return NSAttributedString(string: "Add a class", attributes: attrs)
+    }
+    
+    var emptyStateButtonImage: UIImage? { return #imageLiteral(resourceName: "ButtonBg") }
+    
+    var emptyStateButtonSize: CGSize? { return CGSize(width: 160, height: 45) }
+    
+    var emptyStateViewAnimatesEverytime: Bool { return false }
+    
+    // Empty State Delegate
+    
+    func emptyStateViewWillShow(view: UIView) {
+
+    }
+    
+    func emptyStateViewWillHide(view: UIView) {
+
+    }
+    
+    func emptyStatebuttonWasTapped(button: UIButton) {
+        self.performSegue(withIdentifier: .addEditClass, sender: button)
+    }
+}
+
 
 // MARK: Split View Delegation
 

        splitViewController?.delegate = self
        splitViewController?.preferredDisplayMode = .allVisible
        tableView.scrollsToTop = true
        
        // Remove seperator lines from empty cells, and remove white background around navbars
        tableView.tableFooterView = UIView(frame: CGRect.zero)

        for (i, objs) in classes.enumerated() {
            registerNotifications(for: objs, in: i)
        }
    }
    
    override func viewWillAppear(_ animated: Bool) {
        super.viewWillAppear(animated)
        
        reloadEmptyState()
    }
    
    override func viewDidAppear(_ animated: Bool) {
