 		state = fn(oldState)
 		
 		if componentShouldUpdate(oldState, newState: state) {
-			update()
-		}
+			enqueueRender()
+		}
+	}
+
+	private func enqueueRender() {
+		if needsRender { return }
+
+		needsRender = true
+
+		let observer = CFRunLoopObserverCreateWithHandler(kCFAllocatorDefault, CFRunLoopActivity.Exit.rawValue, 0, 0) { _, _ in
+			self.update()
+			self.needsRender = false
+		}
+		CFRunLoopAddObserver(CFRunLoopGetMain(), observer, kCFRunLoopDefaultMode)
 	}
 
 	/// Get the current state of the component.


	private let renderFn: ((Component<S>, S) -> Element)?

	private var rendering: Bool = false

	private var renderQueued: Bool = false

	/// Initializes the component with its initial state. The render function 
	/// takes the current state of the component and returns the element which 

		}
		
		componentDidUpdate()
	}

	/// Update the component without changing any state.
