MCPcopy Create free account
hub / github.com/DioxusLabs/dioxus / create_script

Method create_script

packages/fullstack-server/src/document.rs:107–124  ·  view source on GitHub ↗
(&self, props: ScriptProps)

Source from the content-addressed store, hash-verified

105 }
106
107 fn create_script(&self, props: ScriptProps) {
108 let children = props.script_contents().ok();
109 self.0.borrow_mut().script.push(rsx! {
110 script {
111 src: props.src,
112 defer: props.defer,
113 crossorigin: props.crossorigin,
114 fetchpriority: props.fetchpriority,
115 integrity: props.integrity,
116 nomodule: props.nomodule,
117 nonce: props.nonce,
118 referrerpolicy: props.referrerpolicy,
119 r#type: props.r#type,
120 ..props.additional_attributes,
121 {children}
122 }
123 });
124 }
125
126 fn create_style(&self, props: StyleProps) {
127 let contents = props.style_contents().ok();

Callers

nothing calls this directly

Calls 3

script_contentsMethod · 0.80
okMethod · 0.45
pushMethod · 0.45

Tested by

no test coverage detected