react-native-windows icon indicating copy to clipboard operation
react-native-windows copied to clipboard

Create a New Architecture cs-app template using C# and .NET

Open jonthysell opened this issue 11 months ago • 8 comments

Summary

Create a modern C# .NET app template for RNW New Architecture projects.

Motivation

To continue support for C# that we started in the Old Architecture.

Basic Example

No response

Open Questions

No response

jonthysell avatar Feb 12 '25 19:02 jonthysell

Greetings,

We're still on RN64! Whenever we upgrade to a version that includes the Paper implementation, we encounter issues with navigation states getting lost. When will the cs-app template be production-ready? And will it resolve this issue since it uses the Fabric implementation?

asaadbaw avatar Feb 18 '25 15:02 asaadbaw

Greetings,

We're still on RN64! Whenever we upgrade to a version that includes the Paper implementation, we encounter issues with navigation states getting lost. When will the cs-app template be production-ready? And will it resolve this issue since it uses the Fabric implementation?

What versions have you tried to update to? What errors are you seeing? A lot has changed under the hood for RNW since 64.

jonthysell avatar Mar 12 '25 18:03 jonthysell

This can't be done for new arch until we get this PR in: https://github.com/microsoft/react-native-windows/pull/13913

Once we do, WIP C# app template here (still has issues, not ready to open PR): https://github.com/jonthysell/react-native-windows/tree/newcsapp

jonthysell avatar Mar 12 '25 18:03 jonthysell

I've tried all versions from 0.65 to 0.78, but they all lose state history. I have nested navigation, and it works fine on Android and iOS. Thanks for the update.

asaadbaw avatar Mar 19 '25 12:03 asaadbaw

Moving this to the backlog for now, a good C# experience will require that #14350 is done, so I'd prefer on having that before letting people start using a C# template (which may need to change a lot depending on how #14350 is implemented).

jonthysell avatar Apr 01 '25 21:04 jonthysell

So looking forward to this. some of the referenced items seem to be done. it is difficult to tell if this is internal Microsoft component references change or something that can receive community help. the work items or dots along the way are unclear. looking forward to cs non-uwp template with new arch. we created our app using old uwp c# template in 0.74, because team is more comfortable with C# and have added lots of custom cs turbo modules to address needs. we stay up to date with latest, but seems like we are affected by uwp constraints which don't apply to our application. Performance capacity issues - which we are analyzing and think are due to large amount of data transfers between plugins (some of them old and don't have turbo module) and JavaScript. we think old native modules continue to work through the old bridge data passing - is this true? how can we tell?

rasane avatar May 15 '25 18:05 rasane

Our team is also interested in continuing with C# on React Native’s New Architecture.

tero-paananen avatar Sep 29 '25 09:09 tero-paananen

Is there any update on providing a C# template for React Native’s New Architecture?

asaadbaw avatar Nov 09 '25 05:11 asaadbaw