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 trialDerek Derek
8,744 Pointswhat is the purpose if "Extract string resource"?
what is the purpose if "Extract string resource" when you can just leave the strings as they are?
1 Answer
Keli'i Martin
8,227 PointsFor small apps, string resources are probably a bit overkill. Yes, it's true that you can leave strings hard-coded in your files. Where string resources really become useful is when you need to localize your app for different regions. Having your strings in these resources instead of hard-coding them allows you to have different string resources for different languages. Imagine needing to go and change all strings in your app, including text on buttons, labels, etc, for all the different languages you need to support.
That's just one advantage to using string resources as opposed to hard-coded strings.