Skip to content

Commit 2008485

Browse files
authored
Merge pull request #18963 from unoplatform/dev/doti/unosdk-docs-exclude-files
docs: Add tip for excluding pages with Uno.Sdk
2 parents bdf10e2 + 8266456 commit 2008485

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

doc/articles/features/using-the-uno-sdk.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,20 @@ By Default when using the Uno.Sdk you get the added benefit of default includes
244244

245245
As discussed above setting `EnableDefaultUnoItems` to false will disable these includes.
246246

247+
> [!TIP]
248+
> When you need to exclude specific files from a particular target framework (such as WebAssembly), you can use a custom MSBuild target:
249+
>
250+
> ```xml
251+
> <Target Name="AdjustAppItemGroups" BeforeTargets="ResolveAssemblyReferences">
252+
> <ItemGroup Condition="'$(TargetFramework)' == 'net9.0-browserwasm'">
253+
> <None Remove="Page.xaml"/>
254+
> <Page Remove="Page.xaml"/>
255+
> </ItemGroup>
256+
> </Target>
257+
> ```
258+
>
259+
> This approach allows you to selectively remove pages from specific target frameworks while maintaining them in others.
260+
247261
## Apple Privacy Manifest Support
248262
249263
Starting May 1st, 2024, Apple requires the inclusion of a new file, the [Privacy Manifest file](https://developer.apple.com/documentation/bundleresources/privacy_manifest_files) (named `PrivacyInfo.xcprivacy`), in app bundles. This file is crucial for complying with updated privacy regulations.

0 commit comments

Comments
 (0)