 	/// The state on which the component depends.
 	private var state: S
 
+	private var rootElement: Element?
 	private var rootRealizedElement: RealizedElement?
 
 	private var hostView: ViewType?

		let otherComponent = unsafeBitCast(other, Component.self)
		hostView = otherComponent.hostView

		if rootRealizedElement == nil || otherComponent.rootRealizedElement == nil { return }

		rootRealizedElement!.element.applyDiff(view, other: otherComponent.rootRealizedElement!.element)

		super.applyDiff(view, other: other)
	}
	
	public override func realize() -> ViewType? {
		realizeInHostView()

		return rootRealizedElement?.view
	}


		rootRealizedElement?.view?.removeFromSuperview()
		rootRealizedElement?.element.derealize()
		hostView = nil
		rootRealizedElement = nil
		
		componentDidDerealize()
	}
