Story: is there a way to use the Roslyn compiler to compile UserControl WPF?
Suppose you want to compile an assembly containing standard C # code and WPF controls (XAML and xaml.cs files) without any csproj, of course.
I found a lot on the Internet about how to compile DLL with Roslyn, nothing about how to handle XAML files?
I know that Visual Studio (or MSBuild) creates a temporary generated file and embeds the BAML file in the resulting assembly. So maybe if I could find a way to generate this intermediate file, I could use it, but all I found is PresentationBuildTasks.MarkupCompilePass, which ultimately needs csproj (well, I can create a project on the fly "but I hope to find something simpler.)
Thanks for any help.
source
share