M
Modular2mo ago
rd4com

:hatching_chick: mojo-new-web-framework

🐣 mojo-new-web-framework https://github.com/rd4com/mojo-new-web-framework Hello, after thinking about web-framework a lot, and working on it for a while, it seem good enough, so it is time for a repo 🔥! hope you gonna like it, it can already do a lot and seem quite user-friendly
No description
5 Replies
rd4com
rd4comOP2mo ago
The idea is: "The back-end and the front-end in the same structs!" It works with websockets, a Dict is on the server for visitors states, that way, less complixity 👍 Doing it that way removes the need for creating rest API, events are sent trough websockets, which is the session, and server send a dom-tree as json then the browser just render it.
rd4com
rd4comOP4w ago
Just updated to 2️⃣4️⃣0️⃣6️⃣ and implemented sessiondata(), it is a session-wide dictionnary so that components can have "global states", note that appdata() is app-wide, "global" to all components, and all visitors! Checkout the screenshot to see how it works, here is an example: https://github.com/rd4com/mojo-new-web-framework/blob/master/app3.mojo
No description
Teszaract
Teszaract2w ago
Seems interesting How to use this? Actually I was thinking of making a Web Framework similar to React. Using Customised Markdown instead of JSX. And style with custom CSS just like React. And everything is a functional component just like React. We can have other Mojo code in the same project like ML code and we can call it in our component. Everything will compile to WASM so that it can run in the browser at native speed. What do you think of this?
rd4com
rd4comOP2w ago
Yes that's an amazing great idea !
Darkmatter
Darkmatter3d ago
ML apps probably want to call out to WebGPU.
Want results from more Discord servers?
Add your server