mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-06-13 13:01:22 +00:00
Attempted to tackle #1622
This commit is contained in:
@ -1076,8 +1076,44 @@ extern "C" {
|
||||
/// with a given sequence of arguments preceding any provided when the new function is called.
|
||||
///
|
||||
/// [MDN documentation](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;
|
||||
#[wasm_bindgen(method, js_name = bind)]
|
||||
pub fn bind0(this: &Function, context: &JsValue) -> 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.
|
||||
///
|
||||
/// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/bind)
|
||||
#[wasm_bindgen(method, js_name = bind)]
|
||||
pub fn bind1(
|
||||
this: &Function,
|
||||
context: &JsValue,
|
||||
arg1: &JsValue,
|
||||
) -> 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.
|
||||
///
|
||||
/// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/bind)
|
||||
#[wasm_bindgen(method, js_name = bind)]
|
||||
pub fn bind2(
|
||||
this: &Function,
|
||||
context: &JsValue,
|
||||
arg1: &JsValue,
|
||||
arg2: &JsValue,
|
||||
) -> 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.
|
||||
///
|
||||
/// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/bind)
|
||||
#[wasm_bindgen(method, js_name = bind)]
|
||||
pub fn bind3(
|
||||
this: &Function,
|
||||
context: &JsValue,
|
||||
arg1: &JsValue,
|
||||
arg2: &JsValue,
|
||||
arg3: &JsValue,
|
||||
) -> Function;
|
||||
|
||||
/// The length property indicates the number of arguments expected by the function.
|
||||
///
|
||||
|
Reference in New Issue
Block a user