使用 React Native 构建 APK 和 EXE

Build APK and EXE with react native

我想使用 React-Native 创建一个应用程序,我知道可以构建 APK 和 IPA。但我想知道是否也可以为桌面 winwdows 应用程序构建一个 EXE?

如果是这样,有没有你好世界的例子?

提前致谢。

在 React Native 中无法为 Windows 构建 exe。

虽然您今天可能无法使用 React Native 开发桌面 Windows 应用程序,但您很快就能做到。

来自 Windows 应用团队 2016 年 4 月 13 日的 announcement

Today, Microsoft and Facebook announced at Facebook’s developer conference, F8 2016, that we’re adding Universal Windows Platform (UWP) support to React Native. This is provided as an open source, community-supported framework. The new UWP support extends the reach of these native apps to a new market of 270 million active Windows 10 devices, and the opportunity to reach beyond mobile devices, to PCs, and even the Xbox One and HoloLens.

2016 年 4 月 13 日来自 announcement by Jonathan Carter 通过 CodePush 博客:

We haven’t published the Windows support to NPM yet, but if you want to check it out, you can view the source and/or install the bits from our Windows branch, which includes an updated readme with setup instructions. Additionally, if you want to check out a sample app that uses React Native for Windows and CodePush, the beautiful and open-sourced F8 App is a great example to play around with. The production version of the app already uses CodePush for iOS and Android, and we implemented a fork of it which includes CodePush support on Windows. Clone the fork, run the setup instructions, and try it out! The above screenshots were taken using it, so feel free to have fun with running the app on the various device emulators.

Windows React Native Example

可能会迟到...但是这个答案可能很有用..react-native-windows 是 Microsoft 对 UWP 的 react native 的官方支持。

https://github.com/Microsoft/react-native-windows