Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialSamuel Seidel
1,481 PointsWhat's up with the IDE's spacing for the switch statement?
switch something {
case 1:
instead of
switch something {
case 1:
2 Answers
rtholen
Courses Plus Student 11,859 PointsDone by convention to improve readability and ease of maintaining the code. However, if desired, your IDE should have a configuration option somewhere where you can customize indentation to your liking.
rtholen
Courses Plus Student 11,859 PointsApologies for misinterpreting. I did see this discussion, which may provide some background on xcode formatting.
Samuel Seidel
1,481 PointsSamuel Seidel
1,481 PointsI actually meant, that, xcode is choosing the second example for formatting. Shouldn't it be doing it the first way?