I tried jquery terminal today and get below:

1. each time user input a command and press 'enter', I can get notified and get that input.
2. this input can be sent to kimchi backend through websocket.
3. kimchi backend forward this command to guest serial console, guest run it and response back the command result.
4. kimchi backend send the command result back to UI through websocket.
5. UI get the command result and call jquery terminal API to show it there.

Issues to discuss:

1. text editor support like 'vim', without other js library support, only jquery terminal, no way to support text editor.
2. any other special command need special handling you see, welcome to discuss.