---
title: Day 42
author: Daniel Devesa Derksen-Staats
date: 2022-06-29 11:20
tags: iOS, isTabBar
categories: ["Accessibility"]
series: ["365 Days iOS Accessibility"]
image: /Images/365DaysIOSAccessibility/image163.jpg
---

I'll never recommend creating a custom component if there is a native one that does the job. But if you develop a custom tab bar, .tabBar accessibility trait comes to the rescue. Apply to a container view and its buttons will be announced as tabs.

![An app that looks like Swarm has a custom tab bar. If the container view of the tab bar has the tabBar accessibility trait and its property isAccessibilityElement is false, its three buttons would be announced as: “selected, personal feed, Tab, 1 of 3”, “check-in, Tab, 2 of 3”, “friends, Tab, 3 of 3”. It indicates they’re tabs and their position in the custom tab bar.](/Images/365DaysIOSAccessibility/image163.jpg)