Skip to content

Is there a way to make custom controls without namespace constraints? #17996

Answered by msneijders
nasterhe asked this question in Q&A
Discussion options

You must be logged in to vote

You can use Avalonia.Metadata.XmlnsDefinitionAttribute. Something like this in a cs file (often called 'CommonNamespace.cs' what I have seen:

[assembly: XmlnsDefinition("https://github.com/avaloniaui", "MySoft")]

Given you have xmlns="https://github.com/avaloniaui" marked in your xaml file.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@nasterhe
Comment options

Answer selected by nasterhe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants