Everytime I add a property to a class with XML comments git thinks I added space below and a summary opening tag below instead of the of the one I wrote. For example, I added the property FirstName (line 16 to 20), but the git diff is (18 to 22). At first, I thought it was a normal behaviour. I think I've seen others git diff that does not have this behaviour.
12 /// <summary>
13 /// Date.
14 /// </summary>
15 public DateTime Date { get; set; }
16
17 /// <summary>
18 /// FirstName.
19 /// </summary>
20 public string FirstName { get; set; }
21
22 /// <summary>
23 /// LastName.
24 /// </summary>
25 public string LastName { get; set; }
Here is a picture for visual representation
It's not that bad, it just makes merge conflicts on properties more time consuming because I need to rewrite the summary tag.
Honestly, I don't even know what to do. I tried to write my code in different manners but can't get rid of this. I've search on internet but can't find a post about this problem.