             self.method = method
             self.eventName = rawDict[JBX_KEY_EVENT_NAME] as? String
             self.code = rawDict[JBX_KEY_CODE] as? Int
-            self.data = rawDict[JBX_KEY_DATA] as? [String: AnyObject]
+            self.data = rawDict[JBX_KEY_DATA]
             self.callbackId = rawDict[JBX_KEY_CALLBACK_ID] as? String
             dict = rawDict
             return


public class JSBridgeX: NSObject, UIWebViewDelegate {
 
    public typealias EventCallback = (code: Int, data: [String: AnyObject]?) -> Void
    public typealias EventHandler = (data: [String: AnyObject]?, callback: EventCallback?) -> Void
    public typealias DefaultEventHandler = (eventName: String, data: [String: AnyObject]?, callback: EventCallback?) -> Void
    
    public static let CODE_SUCCESS = 200
    public static let CODE_NOT_FOUND = 404

        self.webView?.loadRequest(NSURLRequest(URL: url))
    }
    
    public func loadHTMLString(htmlString: String, baseURL: NSURL?) {
        self.webView?.loadHTMLString(htmlString, baseURL: baseURL)
    }
    
    public func registerEvent(eventName: String, handler: EventHandler) {
