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

Syntax Support for Async Binding to Self #16098

Open
djdjz7 opened this issue Jun 24, 2024 · 0 comments
Open

Syntax Support for Async Binding to Self #16098

djdjz7 opened this issue Jun 24, 2024 · 0 comments

Comments

@djdjz7
Copy link

djdjz7 commented Jun 24, 2024

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

As mentioned in #16092 , the following syntax does not work:
code-behind:

private List<Task<Bitmap?>> _illustrations = new();
public List<Task<Bitmap?>> Illustrations
{
    get => _illustrations;
    set => this.RaiseAndSetIfChanged(ref _illustrations, value);
}

axaml:

<Image Source="{Binding ^}" />

or

<Image Source="{Binding .^}" />

In 11.0.11, the first syntax throws compiler errors, while the second one downloads the image, but didn't display it in the UI.

In 11.1-rc, both syntaxes throws compiler errors.

Describe the solution you'd like

Add support for either syntax. Personally I would prefer the first one, as it is more concise, and is similar to the {Binding} syntax.

Describe alternatives you've considered

No response

Additional context

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants