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!
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 trial
Silviu B.3,111 Points
Swift Errors: Best Practice?
In case I have a bigger app, with multiple views, multiple objects and so on... what is the best practice in handling ErrorType enums?
- Should I just create a separate file with an enum called Error and group errors inside this one (creating a group for each section of the app that needs error handling)?
- Should I create enums locally, where needed inside all other documents?
I wonder which option is better or what is the common practice in this case.