maxcountryman_web_sys/features/
gen_PopStateEvent.rs

1#![allow(unused_imports)]
2use super::*;
3use wasm_bindgen::prelude::*;
4#[wasm_bindgen]
5extern "C" {
6    # [wasm_bindgen (extends = Event , extends = :: js_sys :: Object , js_name = PopStateEvent , typescript_type = "PopStateEvent")]
7    #[derive(Debug, Clone, PartialEq, Eq)]
8    #[doc = "The `PopStateEvent` class."]
9    #[doc = ""]
10    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/PopStateEvent)"]
11    #[doc = ""]
12    #[doc = "*This API requires the following crate features to be activated: `PopStateEvent`*"]
13    pub type PopStateEvent;
14    # [wasm_bindgen (structural , method , getter , js_class = "PopStateEvent" , js_name = state)]
15    #[doc = "Getter for the `state` field of this object."]
16    #[doc = ""]
17    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/PopStateEvent/state)"]
18    #[doc = ""]
19    #[doc = "*This API requires the following crate features to be activated: `PopStateEvent`*"]
20    pub fn state(this: &PopStateEvent) -> ::wasm_bindgen::JsValue;
21    #[wasm_bindgen(catch, constructor, js_class = "PopStateEvent")]
22    #[doc = "The `new PopStateEvent(..)` constructor, creating a new instance of `PopStateEvent`."]
23    #[doc = ""]
24    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/PopStateEvent/PopStateEvent)"]
25    #[doc = ""]
26    #[doc = "*This API requires the following crate features to be activated: `PopStateEvent`*"]
27    pub fn new(type_: &str) -> Result<PopStateEvent, JsValue>;
28    #[cfg(feature = "PopStateEventInit")]
29    #[wasm_bindgen(catch, constructor, js_class = "PopStateEvent")]
30    #[doc = "The `new PopStateEvent(..)` constructor, creating a new instance of `PopStateEvent`."]
31    #[doc = ""]
32    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/PopStateEvent/PopStateEvent)"]
33    #[doc = ""]
34    #[doc = "*This API requires the following crate features to be activated: `PopStateEvent`, `PopStateEventInit`*"]
35    pub fn new_with_event_init_dict(
36        type_: &str,
37        event_init_dict: &PopStateEventInit,
38    ) -> Result<PopStateEvent, JsValue>;
39}