News

React Native Windows Team 'Dogfoods' New Update

Microsoft's React Native for Windows dev team announced an update in which the developer experience was improved in part by "dogfooding," referring to the practice of teams using the very same application they created.

Serving as a testament to Microsoft's relatively new embrace of open source technologies, the company's React Native for Windows (and macOS) extension tooling facilitates the use of the popular open source React Native project created by Facebook that burst onto the scene in 2015 with a new way to create mobile apps with JavaScript and the React UI library. That new way followed a "learn once, write anywhere" approach in which the same techniques were used to build native apps for Android, iOS and so on, as opposed to the traditional "write once, run anywhere" cross-platform paradigm.

Microsoft's GitHub rep for the project says it supports the Windows 10 SDK, so it can be used for web, enterprise or gaming apps targeting devices running that OS including PCs, tablets, 2-in-1s, Xbox, Mixed Reality devices (including HoloLens), Surface Hub and more. Apps can be run from within the Visual Studio IDE or without it.

With the advent of React Native 0.64, Microsoft's dev team highlighted the work done to support more community modules, TurboModules, API improvements and tools.

"There's been a lot of work on improving the developer experience, as that's been a focus for us as a whole across all our frameworks and platforms, and React Native for Windows is no exception!" the team said in a blog post earlier this month. "Through tooling, dogfooding our own work, and 'under the hood' improvements, we're looking forward to sharing with you some of the highlights in this release that we're especially proud to announce."

Among those highlights is easier use of Hermes, an open source JavaScript engine optimized for running React Native apps on Android, support for which is still experimental.

Also new is a React Native Gallery app the team created to show off all the functionality of the Windows tool while helping development efforts, such as cross-platform module testing,

React Native Gallery in Animated Action
[Click on image for larger, animated GIF view.] React Native Gallery in Animated Action (source: Microsoft).

"Much like the XAML Controls Gallery for WinUI, we intend to have the React Native Gallery be available not only as a proving ground for our own work, but also a place where native and JavaScript components alike can be seen in action in the Windows ecosystem. This includes providing lightweight code snippets on each page for developers to copy out and use in their own scenarios."

The aforementioned TurboModules, meanwhile, is another experimental feature that serves to allow JavaScript code to load modules only when needed, among other functionality. "We now have support for C++ JSI TurboModules using the same TurboModule interface that is available on Android and iOS. Since these APIs haven't been fully shipped or documented in React Native core yet, these APIs are subject to change."

Other highlights include API parity, with more component properties supported by other platforms now working on Windows, expanded documentation and more.

Other new features include:

  • React 17 and faster startup by default: React Native 0.64 brings the latest version of React, and changes the default metro configuration to enable "inline requires", allowing for faster startup by default.
  • Community module templates: A new workflow makes it easier to create community modules for Windows by using a built-in template.
  • Instance lifecycle events: Native code can now respond to the react native instance being created, loaded, or destroyed.
  • A brand new WebSocket stack: The existing WebSocket stack has been replaced with an all new, more-correct, production-hardened implementation.
  • Bug-fixes and improvements: The above just scratches the surface on the work that has been happening! We've been continually making bug fixes and improvements across the project.

More information is provided in the above-linked blog post, web site and GitHub repo, along with documentation including Get Started with Windows.

For VS Coders, the React Native Tools extension is available in the code editor's marketplace, installed nearly 2 million times.

About the Author

David Ramel is an editor and writer for Converge360.

comments powered by Disqus

Featured

  • Full Stack Hands-On Development with .NET

    In the fast-paced realm of modern software development, proficiency across a full stack of technologies is not just beneficial, it's essential. Microsoft has an entire stack of open source development components in its .NET platform (formerly known as .NET Core) that can be used to build an end-to-end set of applications.

  • .NET-Centric Uno Platform Debuts 'Single Project' for 9 Targets

    "We've reduced the complexity of project files and eliminated the need for explicit NuGet package references, separate project libraries, or 'shared' projects."

  • Creating Reactive Applications in .NET

    In modern applications, data is being retrieved in asynchronous, real-time streams, as traditional pull requests where the clients asks for data from the server are becoming a thing of the past.

  • AI for GitHub Collaboration? Maybe Not So Much

    No doubt GitHub Copilot has been a boon for developers, but AI might not be the best tool for collaboration, according to developers weighing in on a recent social media post from the GitHub team.

  • Visual Studio 2022 Getting VS Code 'Command Palette' Equivalent

    As any Visual Studio Code user knows, the editor's command palette is a powerful tool for getting things done quickly, without having to navigate through menus and dialogs. Now, we learn how an equivalent is coming for Microsoft's flagship Visual Studio IDE, invoked by the same familiar Ctrl+Shift+P keyboard shortcut.

Subscribe on YouTube