How to reuse websocket connection to access myscript api
R
Rajendra P Vennam
started a topic
almost 2 years ago
Hello,
We would like to know how to call myscript web api with only one websocket per a webpage ( where mutiple textboxes's input will be fed by hand written text),
instead of opening a new websocket per every input feild of the form in a webpage. As websocket is a costly ( sometimes it takes 5-10 seconds to open a ws connection ) , we are planning to reuse same connection through out the form.
Please guide us.
Thanks.
Best Answer
R
Romain Cascino
said
almost 2 years ago
Dear Rajendra,
We provide an example with MyScriptJS showing a custom integration with two websockets connections to manage multiple inputs.
The reason we use two and not only one is to always have an available editor to manage the input.
Rajendra P Vennam
Hello,
We would like to know how to call myscript web api with only one websocket per a webpage ( where mutiple textboxes's input will be fed by hand written text),
instead of opening a new websocket per every input feild of the form in a webpage. As websocket is a costly ( sometimes it takes 5-10 seconds to open a ws connection ) , we are planning to reuse same connection through out the form.
Please guide us.
Thanks.
Dear Rajendra,
We provide an example with MyScriptJS showing a custom integration with two websockets connections to manage multiple inputs.
The reason we use two and not only one is to always have an available editor to manage the input.
You can find the example online on github here Multiple inputs and the source code here : HTML and Javascript.
Best regards,
Romain - Web developer @MyScript
Romain Cascino
Dear Rajendra,
We provide an example with MyScriptJS showing a custom integration with two websockets connections to manage multiple inputs.
The reason we use two and not only one is to always have an available editor to manage the input.
You can find the example online on github here Multiple inputs and the source code here : HTML and Javascript.
Best regards,
Romain - Web developer @MyScript