View Source ExTerm.TerminalBackend (ex_term v0.2.1)
Default backend that creates a ExTerm.IoServer
process and forwards all
callbacks to its wrapping module. By default, this is set to
ExTerm.TerminalBackend.IoServer
.
terminalbackend-specific-options
TerminalBackend specific options:
This option can be set in the router declaration (see ExTerm.Router
)
:io_server
a module, should be a supervisableGenServer
which satisfies a minimal set ofExTerm.IoServer
callbacks. The required implementations are as follows:- list coming in v 0.3.0
Example
live_term "/", pubsub_server: MyWebApp.PubSub, io_server: MyIoServer
terminalbackend-ioserver-specific
TerminalBackend.IoServer specific
This option can be set in the router declaration (see ExTerm.Router
)
:terminal
a (module, function, args) for the function that should be run inside of the terminal task. This should be a REPL that takes over the task, and typically will be an infinite loop (return typeno_return
). If the function terminates, the io server will suffer a fatal error and the terminal liveview will be rendered unusable.Example
live_term "/", pubsub_server: MyWebApp.PubSub, terminal: {MyModule, :run, []}