mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-06-17 15:01:23 +00:00
bool -> boolean in generated TypeScript code (#1933)
* bool -> boolean in generated TypeScript code * Add a test for booleans Co-authored-by: Alex Crichton <alex@alexcrichton.com>
This commit is contained in:
committed by
Alex Crichton
parent
e169f45e1a
commit
620212dff8
@ -2,3 +2,6 @@ use wasm_bindgen::prelude::*;
|
||||
|
||||
#[wasm_bindgen]
|
||||
pub fn greet(_: &str) {}
|
||||
|
||||
#[wasm_bindgen]
|
||||
pub fn take_and_return_bool(_: bool) -> bool { true }
|
||||
|
@ -2,4 +2,5 @@ import * as wbg from '../pkg/typescript_tests';
|
||||
import * as wasm from '../pkg/typescript_tests_bg';
|
||||
|
||||
const wbg_greet: (a: string) => void = wbg.greet;
|
||||
const wasm_greet: (a: number, b: number) => void = wasm.greet;
|
||||
const wasm_greet: (a: number, b: number) => void = wasm.greet;
|
||||
const take_and_return_bool: (a: boolean) => boolean = wbg.take_and_return_bool;
|
||||
|
Reference in New Issue
Block a user