1

ImageView contentDescription Why does it give a warning when I use it?

1

Thank you for your attention

contentDescription you mind if I don't write a description?

ADM
  • 20,406
  • 11
  • 52
  • 83
Arzu Kaya
  • 11
  • 3

1 Answers1

1

Well, the ImageView will work without contentDescription however, you probably should know what it is used for:

Users of accessibility services, such as screen readers, rely on content labels to understand the meaning of elements in an interface. In some cases, such as when information is conveyed graphically within an element, content labels can provide a text description of the meaning or action associated with the element. If elements in a user interface don't provide content labels, it can be difficult for some users to understand the information presented to them or to perform actions in the interface.

So you probably should include one if you want your app to work on screen readers.

JustSightseeing
  • 1,460
  • 3
  • 17
  • 37