简体   繁体   中英

How to use Reactjs code to develop windows desktop application

本质上我们一直在做一个产品,我们使用 Reactjs 开发 web 客户端,但现在对 windows 桌面应用程序有需求,我们可以使用 Reactjs 代码开发 windows 桌面应用程序。

You should look at Electron .

If you can build a website, you can build a desktop app. Electron is a framework for creating native applications with web technologies like JavaScript, HTML, and CSS. It takes care of the hard parts so you can focus on the core of your application.

The section 'Apps built on Electron' is a great start as you might recognise some applications that are built using Electron and you are using it already. Given the understanding of possibility, they have excellent documentation and a starting video, both linked on homepage.

It depends on how you are developing your desktop app. For example; if you are using ElectronJS to develop your app, you can use your react code for front-end purpose. Should work just fine.

Officially react doesn't support desktop yet. There are some libraries with several issues and long term support can't be guaranteed. Some libraries are -

https://reactdesktop.js.org/ https://proton-native.js.org/

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM