I am creating SegmentedBar in native script. I am able to create segments but I am not able to add Label to segment view.
You may know the
is created keeping in mind to show different pages/views in single page/view. Thus, TabView is used mainly for navigating to different views.
The SegmentedBar
is created for different purpose. This can be used in a view with different functionality for example you can categorize the contents/products as Free, Paid. You would want to show different product features, services on Free view and Paid view. Thus, you can use the SegmentedBar
to show different options for the user.
So, now you know the difference between the TabView
and the SegmentedBar
.
The correct use of SegmentedBar
is to use like this:
To conclude, use TabView
for navigating multiple pages in single page and use SegmentedBar
for viewing different content in a single view.