Mobile development

Stage 2 · Lesson 8 of 10

Images and resources

Jetpack Compose UI

Android keeps assets that are not code in res folders. Strings go in res/values/strings.xml, images in drawable, and icons are . In you load them with stringResource(R.string.title) and painterResource(R.drawable.logo).

Material icons come from Icons.Default or Icons.Filled. Keep every string the user sees in strings.xml, so the app can be translated and text is not scattered through code. For images from the internet, use a library such as .

Its AsyncImage handles downloading, caching, placeholders and errors, and works well inside . Always set contentDescription for meaningful images and null for decorative ones.

Common traphard-coding text in composables and loading full-size photos into small thumbnails.

A question to check yourself, an AI practice session and 1 cheat sheet entry come with the full roadmap. Unlock

Resources for this stage

Start with

Practise

  • Use a free challenge's mobile design image as the spec for a native screen

Keep handy

  • Spacing, type scale, colour and component specs your screens should follow

Mark this stage as not done?