I am currently reading Pro WPF book in C # 2008 and I am new to WPF.
I basically have questions regarding best practice, since I want to write code that is usually accepted by other developers.
Throughout the book, I see that the author uses different ways to close tags for different purposes. I will give an example:
When creating a grid and defining rows and columns, it always writes this code, similar to this:
<Grid.ColumnDefinitions>
<ColumnDefinition />
<ColumnDefinition />
</Grid.ColumnDefinitions>
Thus, it closes the inline tag inside the tag, since the tag has no content (I'm not sure if the line is the correct wording for this)
But in most other places, it will add a closing tag, even if it does not contain such content
<TextBlock Text="{Binding Path=CategoryName}"></TextBlock>
, - ColumnDefinition, ,
<ColumnDefinition Width="Auto"></ColumnDefinition>
. ? , , , .
, .