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

Hot Reload doesn't reflect changes made on base class's content (CSharp Markup) #15993

Open
abbatepabloo opened this issue Mar 22, 2024 · 1 comment
Labels
area/external Categorizes an issue or PR as being external to the Uno

Comments

@abbatepabloo
Copy link

Current behavior

Runtime changes made to a base class's content are not reflected by the app. In the attached example, there is a MainPageBase class that is responsible for rendering the content. If you made any change at runtime to this content you won't be able to see it reflected on the UI. If you restart the app you will see the change applied

public sealed partial class MainPage : MainPageBase
{
}

public partial class MainPageBase : Page
{
    public MainPageBase()
    {
        this.DataContext<MainViewModel>((page, vm) => page
            .Content(new Grid()
                .Children(...);
    }
}

Expected behavior

At runtime, you should see the changes made to the content of a base class

How to reproduce it (as minimally and precisely as possible)

UnoApp1.zip
To reproduce the issue:

  • Uncompress the attached file and, using Visual Studio, run UnoApp1.Windows project
  • Once the app is up and running edit MainPage.cs and remove all exclamation points contained in the string of line 29.

You should see this change reflected on the form.

Workaround

No response

Works on UWP/WinUI

None

Environment

No response

NuGet package version(s)

No response

Affected platforms

No response

IDE

Visual Studio 2022

IDE version

Microsoft Visual Studio Community 2022 (64-bit) - Preview Version 17.10.0 Preview 1.0

Relevant plugins

No response

Anything else we need to know?

No response

@abbatepabloo abbatepabloo added difficulty/tbd Categorizes an issue for which the difficulty level needs to be defined. kind/bug Something isn't working triage/untriaged Indicates an issue requires triaging or verification labels Mar 22, 2024
@jeromelaban jeromelaban added area/hot-reload Categorizes an issue or PR as relevant to hot reload and removed triage/untriaged Indicates an issue requires triaging or verification labels Mar 25, 2024
@jeromelaban
Copy link
Member

Hot Reload on Windows has improved since then, but there's still a VS issue when running unpackaged.

@jeromelaban jeromelaban added area/external Categorizes an issue or PR as being external to the Uno and removed kind/bug Something isn't working difficulty/tbd Categorizes an issue for which the difficulty level needs to be defined. area/hot-reload Categorizes an issue or PR as relevant to hot reload labels Nov 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/external Categorizes an issue or PR as being external to the Uno
Projects
None yet
Development

No branches or pull requests

2 participants