avalonia-dotnet-templates icon indicating copy to clipboard operation
avalonia-dotnet-templates copied to clipboard

Avalonia xPlat Library template

Open workgroupengineering opened this issue 11 months ago • 2 comments

Is your feature request related to a problem? Please describe.

Guidelines for developing an Avalonia xPlat library that supports trimming and calls the native platforms library.

Describe the solution you'd like

Create simple template project

Describe alternatives you've considered

No response

Additional context

No response

workgroupengineering avatar Aug 01 '23 09:08 workgroupengineering

That's a normal .NET library with Avalonia reference. To add extra platforms, you either keep everything the same and PInvoke native APIs, or add a native platform target, like "net6.0-android". Not sure what can be/should be done here in templates.

maxkatz6 avatar Aug 02 '23 23:08 maxkatz6

I would like to try porting CameraView from Xamarin.CommunityToolkit to Avalonia.

I'd like a guideline of how to do this to avoid future brecking changes with Avalonia.

For example you could use a library with tagrt framework netstandard or a multi targets library.

If there was a template there would be no such doubts.

workgroupengineering avatar Aug 03 '23 13:08 workgroupengineering