js-sys: Add extends to JSON

Part of #670
This commit is contained in:
Nick Fitzgerald
2018-09-06 13:32:31 -07:00
parent cda71757d3
commit 5df2347a7a
2 changed files with 18 additions and 2 deletions

View File

@ -3048,8 +3048,12 @@ pub mod WebAssembly {
// JSON
#[wasm_bindgen]
extern "C" {
/// The `JSON` object contains methods for parsing [JavaScript Object
/// Notation (JSON)](https://json.org/) and converting values to JSON. It
/// can't be called or constructed, and aside from its two method
/// properties, it has no interesting functionality of its own.
#[derive(Clone, Debug)]
#[wasm_bindgen(extends = Object)]
pub type JSON;
/// The `JSON.parse()` method parses a JSON string, constructing the