The problem is solved. Another developer added a dependency to the project, but stored the source code in his personal Git account.
When I pulled the code from the company Git, this dependency was left out.
So, when the CodeBehindGenerator tried to parse the page XAML, it found this tags, which it could not resolve, throwing the null exception.
The strange thing is that it did not generate the InitializeComponent for any page, and not just to the page that used the broken XAML tag.
Fix the broken dependency fixed the CodeBehindGenerator and the InitializeComponent.