         removeKeyboardObservers()
     }
 
-    // MARK: - Methods
-
+    // MARK: - Methods [Private]
+
+    /// Sets the delegate and dataSource of the messagesCollectionView property.
     private func setupDelegates() {
         messagesCollectionView.delegate = self
         messagesCollectionView.dataSource = self
     }
 
+    /// Registers all cells and supplementary views of the messagesCollectionView property.
     private func registerReusableViews() {
 
         messagesCollectionView.register(TextMessageCell.self)

import UIKit

open class MessagesViewController: UIViewController {

    // MARK: - Properties

    open var messagesCollectionView = MessagesCollectionView()

    open var messageInputBar = MessageInputBar()
    
    open var scrollsToBottomOnFirstLayout: Bool = false

    open var scrollsToBottomOnKeybordBeginsEditing: Bool = false

    private var isFirstLayout: Bool = true

    open override var canBecomeFirstResponder: Bool {
        return true


    }

    /// Adds the messagesCollectionView to the controllers root view.
    private func setupSubviews() {
        view.addSubview(messagesCollectionView)
    }

    /// Sets the constraints of the `MessagesCollectionView`.
    private func setupConstraints() {
        messagesCollectionView.translatesAutoresizingMaskIntoConstraints = false

