Commit 563844d7 authored by Stephane Glondu's avatar Stephane Glondu

Use textContent instead of innerHTML to extract strings from DOM

parent 2502950d
......@@ -32,7 +32,7 @@ let withElementById x f =
let getHtmlById x =
let r = ref x in
withElementById x (fun x ->
r := Js.to_string x##innerHTML
Js.Opt.iter (x##textContent) (fun x -> r := Js.to_string x)
); !r
let alert s : unit =
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment