Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

165
Views
Hide Bottom Tabs Navigator Dynamically

I have a modal.

const RenderModal = ({
    modalActive,
}) => {
    return (
        <Modal
            animationType="slide"
            transparent={true}
            visible={modalActive}
        >
        </Modal>
    )
}

I render my modal in my parent view like this;

<RenderModal
    modalActive={modalActive}
/>

I activate my modal in my parent view like this;

<TouchableOpacity
    onPress={() => {
        setModalActive(true)
    }}
>
</TouchableOpacity>

When modal is active, bottom tabs navigator is still visible.

I want to change bottom tabs navigator visibility dynamically.

To achive this I added below to my parent view;

import { useNavigation } from '@react-navigation/native';
const navigation = useNavigation();

Then I activate my modal like this;

<TouchableOpacity
    onPress={() => {
        navigation.setOptions({ tabBarVisible: false });
        setModalActive(true)
    }}
>
</TouchableOpacity>

navigation.setOptions({ tabBarVisible: false }) is not working.

How can I hide my bottom tabs navigator dynamically?

Edit:

Below is not working also.

useEffect(() => {
  navigation.setOptions({tabBarVisible: !modalActive});
}, [modalActive])
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

You have to change tabbar style.

tabBarOptions: {{
 style: {
   height: isShow?140:0,
   overflow: isShow?'visible':'hidden'
 }
}}
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!