Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create example for Windows #2312

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from
Draft

Conversation

adrianryt
Copy link
Contributor

@adrianryt adrianryt force-pushed the create-windows-example-app branch from f1f3cc0 to 53648e7 Compare August 22, 2024 12:03
@adrianryt adrianryt force-pushed the create-windows-example-app branch from 53648e7 to 6e4f0c9 Compare August 22, 2024 12:08
</PropertyGroup>
<Import Project="$(ReactNativeWindowsDir)\PropertySheets\External\Microsoft.ReactNative.WindowsSdk.Default.props" Condition="Exists('$(ReactNativeWindowsDir)\PropertySheets\External\Microsoft.ReactNative.WindowsSdk.Default.props')" />
<PropertyGroup Label="Fallback Windows SDK Versions">
<WindowsTargetPlatformVersion Condition=" '$(WindowsTargetPlatformVersion)' == '' ">10.0.18362.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformMinVersion Condition=" '$(WindowsTargetPlatformMinVersion)' == '' ">10.0.16299.0</WindowsTargetPlatformMinVersion>
<WindowsTargetPlatformMinVersion Condition=" '$(WindowsTargetPlatformMinVersion)' == '' ">10.0.17763.0</WindowsTargetPlatformMinVersion>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Acording to https://github.com/microsoft/microsoft-ui-xaml For WinUI, your app's users must be on Windows 10 1809 - Build 17763 or newer.

@@ -15,12 +15,12 @@
<ApplicationTypeRevision>10.0</ApplicationTypeRevision>
</PropertyGroup>
<PropertyGroup Label="ReactNativeWindowsProps">
<ReactNativeWindowsDir Condition="'$(ReactNativeWindowsDir)' == ''">$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), 'node_modules\react-native-windows\package.json'))\node_modules\react-native-windows\</ReactNativeWindowsDir>
<ReactNativeWindowsDir Condition="'$(ReactNativeWindowsDir)' == ''">$([MSBuild]::GetDirectoryNameOfFileAbove($(SolutionDir), 'node_modules\react-native-windows\package.json'))\node_modules\react-native-windows\</ReactNativeWindowsDir>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Solution from react-native-windows repo: microsoft/react-native-windows#5911 (comment)
the general fix for having an example app with its own pacakage.json/node_modules in the same repo as their module, and therefore ending up with two copies of react-native-windows - is to update the ReactNativeWindowsDir property in the module's project

@adrianryt adrianryt force-pushed the create-windows-example-app branch from 2399ce4 to 64a9e79 Compare August 26, 2024 13:16
@adrianryt adrianryt force-pushed the create-windows-example-app branch from 326d456 to ec5e88a Compare September 23, 2024 13:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant