Sreejith Sree
Sreejith Sree

Reputation: 3716

Xamarin Forms:ImageCircle package is not working in release mode UWP

For the circle image, I am using Xam.Plugins.Forms.ImageCircle package and it is working fine in debug mode.

But in release mode, all the pictures are in square format. I uninstall and reinstall the nuget. Also, do clean, rebuild and deleting bin and obj folders, but still the issue is not resolved.

Thanks in advance

Upvotes: 0

Views: 601

Answers (1)

Gerald Versluis
Gerald Versluis

Reputation: 34073

You might be running into this piece of the documentation.

For linking you may need to add:

Android:

ImageCircle.Forms.Plugin.Abstractions;ImageCircle.Forms.Plugin.Android;

iOS:

--linkskip=ImageCircle.Forms.Plugin.iOS --linkskip=ImageCircle.Forms.Plugin.Abstractions

Add this to your platform project build options.

Android

Add linking skip on Android

iOS

Add linking skip on iOS

You should only need to add this on the Release configuration.

For UWP, you just have to create a small, trivial reference to the CircleImage assembly to keep it included in a release build. Add this piece of code above the Xamarin.Forms Init line:

var rendererAssemblies = new[]
{
    typeof(ImageCircleRenderer).GetTypeInfo().Assembly
};
Xamarin.Forms.Forms.Init(e, rendererAssemblies);

Upvotes: 3

Related Questions