Hi, new to KVision (read the doc and read realworl...
# kvision
f
Hi, new to KVision (read the doc and read realworldapp)/ Kotlinjs , can I ask a few questions : • js produced by KVision can be integrated into a microfront end host ? I think it is • anyone can give me a pointer to integrate SSE ?
r
Hello
KVision (like any other kotlin/js app) is compiled to the plain javascript. I think it should be possible to integrate this code with some micro fronted framework, but I have no experience with this.
Googling a bit I've found https://single-spa.js.org/docs/examples. I see react, vue, angular there - I don't think KVision app is much different.
f
Me too. We are currently using nx and angular. • Nx offers some tools / guide to build a host :under the hood it is webpack module federation. So any js runtime can be consumed I think • I found Angular / rxjs / styling heavyweight. Perhaps and surely I lack experience / skills. Angular signals is told to be "lighter". In any way I'm searching to evaluate others solutions 🙂 KVision docs is really cool. Code is readable (more than vaadin a first sight)
yes thanks a lot Robert 🙂
r
As for SSE - currently it's not supported.
But there is already a fresh issue about this - https://github.com/rjaros/kvision/issues/477
I think I'll try to implement this in the near future.
f
Thanks !
r
The question is do you want to use SSE with KVision fullstack interfaces? If so, you can probably just use websockets - I think it would be very similar api (KVision hides all the complexity).
But if you just want to use SSE ("manually") from a client app - you can probably just use SEE Web API (https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events)
EventSource
seems to be present in the kotlin/js stdlib
f
We have a Java Spring boot backend (2.7.x). Switch to Kotlin backend not planned Thanks for the pointer to kotlinjs