Hi guys! :slightly_smiling_face: I want to write a...
# javascript
a
Hi guys! 🙂 I want to write an app that can be viewed in a web browser. I want to draw a lot of lines, squares etc on some canvas and make animations. I want to make some file processing (10-15 mb per file). I wish to load the entire file into RAM to speed things up. Not sure if I need multithreading. I have NO knowledge of JS\CSS\HTML at all, but I know Kotlin. What framework\library should I use for this task? Thanks!
b
I'm affraid kotlin is not a silver bullet. You'll still need to learn at least basic js/css/html to be able to work with kotlin.js in a browser environment.
v
And JS is single-threaded, so no, you don't need multithreading. But maybe you want to use coroutines.
t
Well, you can use web workers for multithreading. You may try my application template. This is quite straightforward: clone project, run customization in gradle, put everything in Home.kt, run jsBrowserRun and that's it. Evertything is written in README.md and there is quite extensive documentation on the web. No JS/HTML/CSS needed. This also includes a server (based on Ktor) with a minimal user management but you can easily comment that out. https://github.com/spxbhuhb/zakadabar-application-template
👍🏾 1
n
You can also check out Doodle. It doesn't use JS/CSS/HTML in any APIs. So your app won't need them. But it gives you a Canvas abstraction for drawing. This means lines etc. are very easy to create. This shows how simple it is to create a 3D cube. It also supports animations, as you can see in the search bar (focus/unfocus) of this example app. The code for this is straight forward.
a
thank you guys!