seems to kinda work, the userspace errors missing Html_types module

This commit is contained in:
cqc
2024-03-24 22:50:57 -05:00
parent f46dc86c6a
commit 3c32f068fb
7 changed files with 46 additions and 40 deletions

View File

@ -18,18 +18,29 @@ let resize ~container ~textbox () =
container##.scrollTop := container##.scrollHeight;
Lwt.return ()
let appendchild ~container html =
Dom.appendChild container (Tyxml_js.To_dom.of_a html)
let _ =
Dom_html.window##.onload
:= Dom_html.handler (fun _ ->
Lwt.async (fun () ->
let output = by_id "output" in
let container = by_id "toplevel-container" in
appendchild ~container
Tyxml_js.Html.(
a
~a:[ a_class [ "window" ] ]
[
div
~a:[ a_class [ "status" ] ]
[ txt "starting..." ];
]);
let textbox : 'a Js.t =
by_id_coerce "userinput" Dom_html.CoerceTo.textarea
in
let rootrepo = Store.test_pull () in
rootrepo >>= fun (upstream, t) ->
rootrepo >>= fun (_upstream, t) ->
Store.S.tree t >>= fun rootstore ->
(try
Store.S.Tree.get rootstore [ ".config"; "init.ml" ]
@ -88,7 +99,8 @@ let _ =
Sync.pull_exn t upstream `Set
>>= fun _ ->
Firebug.console##log
(Js.string "Nav.test_pull(6)\n");
(Js.string
"re-pulling rootstore for init.ml\n");
tree t >>= fun rs ->
(try
Store.S.Tree.get rs