Hey guys,
I'm working on a browser-based IDE for Nim that uses either nim secret or inim as the REPL. What I'd like to do is send scripts to the REPL's stdin and receive responses via its stdout for printing it out in the browser.
I've tried building a quick demo with a few different examples I've found, but I keep running into the same problem- I'm not able to send the data to the stdin. I know the inputstream is passing data though. I also know the outputstream is fine, so if there was a command registered it would print it out.
Does there some sort of command I need to send, like an enter key, following the data I'm trying to send to the REPL?
Any ideas? I'm ready to go down whatever rabbit hole I need to
I've developed a similar tool to implement a CAAS (compiler as a service) to implement a REPL (unlike inim, it doesn't recompile everything on each cmd; unlike nim secret, it can use c backend), it uses a client server architecture with a cmdline frontend for the REPL that talks to a backend in a separate process; they communicate via AsyncHttpClient.
Still a WIP but POC works and gives performance comparable to nim secret, but with c backend
browser-based IDE for Nim
Just wondering, if it's possible to create interactive browser documents? Like ObservableHQ.
I mean, pure browser, code Nim in browser, without any involvement of the server, the compilation and evaluation of the code happens in browser.