Make the Default Connection String a user rather than project setting
The Default Connection String belongs to the user and should not travel with the project through source control to other users/developers. This is where the shadow DB is kept and should be private to the user.
Not all developers can use localdb, firstly as this doesn't support SQL Server Enterprise features and secondly their localdb may be configured differently.
Therefore, each developer should be able to set and maintain their own Default Connection String.
The solution is simple, move this from the .sqlproj to .sqlproj.user file which does not/should not be checked in to source control.