Merge pull request #1032 from derekdreery/window_docs

Add manual docs for single manual function.
This commit is contained in:
Alex Crichton 2018-11-13 09:56:45 -06:00 committed by GitHub
commit 8520a54f63
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -20,6 +20,13 @@ extern crate wasm_bindgen;
#[allow(unused_imports)]
use js_sys::Object;
/// Getter for the `Window` object
///
/// [MDN Documentation]
///
/// *This API requires the following crate features to be activated: `Window`*
///
/// [MDN Documentation]: https://developer.mozilla.org/en-US/docs/Web/API/Window
#[cfg(feature = "Window")]
pub fn window() -> Option<Window> {
use wasm_bindgen::JsCast;