fix: make `componentsToAddress` usable from JS
ci/woodpecker/push/woodpecker Pipeline was successful
Details
ci/woodpecker/push/woodpecker Pipeline was successful
Details
parent
38faae33bf
commit
36553c5f61
|
@ -29,6 +29,15 @@ pub struct AddressComponents {
|
|||
pub c: Option<String>,
|
||||
}
|
||||
|
||||
#[cfg(feature = "wasm")]
|
||||
#[wasm_bindgen]
|
||||
impl AddressComponents {
|
||||
#[wasm_bindgen(constructor)]
|
||||
pub fn new(t: String, c: Option<String>) -> Self {
|
||||
AddressComponents { t, c }
|
||||
}
|
||||
}
|
||||
|
||||
/// multicodec RAW code
|
||||
const RAW: u64 = 0x55;
|
||||
|
||||
|
|
Loading…
Reference in New Issue