I create the extension with make packed.zip but when I load it in my browser and open a site on which it should be executed, I get the following error:
RuntimeError: unreachable executed macro_railroad_ext.js line 36 > WebAssembly.compile:1667270:1
System information:
Firefox: v93.0
OS: Linux
rustc 1.56.0 (09c42c458 2021-10-18)
cargo 1.56.0 (4ed5d137b 2021-10-04)
cargo web 0.6.26
I think it has to do with calling the DOM api or something. For example, the following code does not result in this error:
#[cfg_attr(cargo_web, js_export)]
pub fn load() {
let x = 1+1;
/*if let Err(err) = priv_load() {
stdweb::console!(error, format!("{:?}", err))
}*/
}
However, the following results in the error:
#[cfg_attr(cargo_web, js_export)]
pub fn load() {
let x = 1+1;
stdweb::console!(error, "asdf");
/*if let Err(err) = priv_load() {
stdweb::console!(error, format!("{:?}", err))
}*/
}
I create the extension with
make packed.zip
but when I load it in my browser and open a site on which it should be executed, I get the following error:System information:
v93.0
1.56.0 (09c42c458 2021-10-18)
1.56.0 (4ed5d137b 2021-10-04)
0.6.26
I think it has to do with calling the DOM api or something. For example, the following code does not result in this error:
However, the following results in the error: