Похожие чаты

Hi guys i have a question from those of you

who use rust in backend tnx in advance for guiding me
i'm a react developer and i'm trying to learn rust in order to use in backend but the problem i'm facing is that most of the ways i've seen to ssr react is through a node js server
i was wondering do other frameworks like vue/angular ... support ssr better than react with a rust server ?
i'm curious to know what js framework you use with a rust backend which handles ssr nice and ez

1 ответов

11 просмотров

I don't think there is any easy way to do this. The thing about ssr with js frameworks like react, Vue, angular etc is that you need to be able to process js from the backend. This is quite straightforward with nodejs because it's a js runtime. To perform ssr for js frameworks on a rust server you would first need some sort of js runtime or processor associated with the rust backend. Nodejs being a js runtime similar to the browser, it's able to execute the js code that renders the output of react and Vue, use libraries like isomorphic-fetch to fetch data regardless of whether the runtime is the server or browser and a whole bunch of other things. Doing all this on a rust server is not impossible, but it's certainly very difficult. This being the case, I'm not aware of any js framework that's ez to use with a rust backend. I have come across projects based on wasm that perform some of the work that react, Vue etc does on the js runtime, but in wasm (obviously); but they were all experimental in nature for the most part. The most promising one in my opinion is https://yew.rs/docs/ If it's absolutely necessary that you use a rust backend, it might be easier to use a framework like this instead of any js framework. You could also try to implement something similar on your own for your preferred js framework if you're looking for a challenge. Hope this answers your question.

Похожие вопросы

Обсуждают сегодня

Господа, а что сейчас вообще с рынком труда на делфи происходит? Какова ситуация?
Rꙮman Yankꙮvsky
29
А вообще, что может смущать в самой Julia - бы сказал, что нет единого стандартного подхода по многим моментам, поэтому многое выглядит как "хаки" и произвол. Короче говоря, с...
Viktor G.
2
@Benzenoid can you tell me the easiest, and safest way to bu.y HEX now?
Živa Žena
20
This is a question from my wife who make a fortune with memes 😂😂 About the Migration and Tokens: 1. How will the old tokens be migrated to the new $LGCYX network? What is th...
🍿 °anton°
2
30500 за редактор? )
Владимир
47
а через ESC-код ?
Alexey Kulakov
29
What is the Dex situation? Agora team started with the Pnetwork for their dex which helped them both with integration. It’s completed but as you can see from the Pnetwork ann...
Ben
1
Гайс, вопрос для разносторонее развитых: читаю стрим с юарта, нада выделять с него фреймы с определенной структурой, если ли чо готовое, или долбаться с ринг буффером? нада у...
Vitaly
9
Anyone knows where there are some instructions or discort about failed bridge transactions ?
Jochem
21
@lozuk how do I get my phex copies of my ehex from a atomic wallet, to move to my rabby?
Justfrontin 👀
11
Карта сайта