mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-06-23 01:31:34 +00:00
bindings for Function.prototype.bind()
This commit is contained in:
@ -325,6 +325,13 @@ extern "C" {
|
||||
#[wasm_bindgen(method)]
|
||||
pub fn apply(this: &Function, context: &JsValue, args: &Array) -> Function;
|
||||
|
||||
/// The bind() method creates a new function that, when called, has its this keyword set to the provided value,
|
||||
/// with a given sequence of arguments preceding any provided when the new function is called.
|
||||
///
|
||||
/// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/bind
|
||||
#[wasm_bindgen(method)]
|
||||
pub fn bind(this: &Function, context: &JsValue) -> Function;
|
||||
|
||||
/// The length property indicates the number of arguments expected by the function.
|
||||
///
|
||||
/// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/length
|
||||
|
Reference in New Issue
Block a user