Add initial_value attribute & fix static special attribute handling (#1063)
* feat & fix: initial_value attribute, special attribute handling * revision: rename js file * fix: rustfmt * fix: clippy * fix: desktop not finding common.js * fix: desktop failing to render Missed a single ``this.SetAttributeInner`` as it was now ``setAttributeInner`` Javascript didn't even throw any errors about this smh * revision: no need for match statement
This commit is contained in:
1 parent
0f684f0567
commit
d09c92beda
9 files changed
+82
-18
No files matched your search
@@ -1,4 +1,5 @@
|
||||
pub static INTERPRETER_JS: &str = include_str!("./interpreter.js");
|
||||
pub static COMMON_JS: &str = include_str!("./common.js");
|
||||
|
||||
#[cfg(feature = "sledgehammer")]
|
||||
mod sledgehammer_bindings;
|
||||
@@ -10,3 +11,13 @@ mod bindings;
|
||||
|
||||
#[cfg(feature = "web")]
|
||||
pub use bindings::Interpreter;
|
||||
|
||||
// Common bindings for minimal usage.
|
||||
#[cfg(feature = "minimal_bindings")]
|
||||
pub mod minimal_bindings {
|
||||
use wasm_bindgen::{prelude::wasm_bindgen, JsValue};
|
||||
#[wasm_bindgen(module = "/src/common.js")]
|
||||
extern "C" {
|
||||
pub fn setAttributeInner(node: JsValue, name: &str, value: JsValue, ns: Option<&str>);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user