mirror of
https://github.com/fluencelabs/wasm-bindgen
synced 2025-03-31 01:11:06 +00:00
remove unnecessary space before function name in .d.ts file
This commit is contained in:
parent
019a0863c4
commit
23ccd3b5c1
@ -734,7 +734,11 @@ impl<'a, 'b> Js2Rust<'a, 'b> {
|
|||||||
.map(|s| format!("{}: {}", s.0, s.1))
|
.map(|s| format!("{}: {}", s.0, s.1))
|
||||||
.collect::<Vec<_>>()
|
.collect::<Vec<_>>()
|
||||||
.join(", ");
|
.join(", ");
|
||||||
let mut ts = format!("{} {}({})", prefix, self.js_name, ts_args);
|
let mut ts = if prefix.is_empty() {
|
||||||
|
format!("{}({})", self.js_name, ts_args)
|
||||||
|
} else {
|
||||||
|
format!("{} {}({})", prefix, self.js_name, ts_args)
|
||||||
|
};
|
||||||
if self.constructor.is_none() {
|
if self.constructor.is_none() {
|
||||||
ts.push_str(": ");
|
ts.push_str(": ");
|
||||||
ts.push_str(&self.ret_ty);
|
ts.push_str(&self.ret_ty);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user