question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Appearance/Disappearance of a scene?

See original GitHub issue

How do we know when a scene is going to appear/disappear? In native iOS development it’s very common to do some extra work in viewWillAppear/viewDidAppear/viewWillDisappear/viewDidDisappear. Is it supported in this repo currently?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:29 (29 by maintainers)

github_iconTop GitHub Comments

1reaction
grahammendickcommented, Nov 6, 2019

Don’t forget to remove your listeners, too

handleNavigation(oldState, state, data, _, stateContext) {
  const crumb = stateNavigator.stateContext.crumb;
  if (stateContext.crumb === crumb)
    // did Appear
  else
    // did Disappear
})
componentDidMount() {
  this.stateNavigator.onNavigate(this.handleNavigation);
}
componentWillUnmount() {
  this.stateNavigator.offNavigate(this.handleNavigation);
}
0reactions
grahammendickcommented, May 28, 2020

Hey @emerson233 . How’s it going?

I’ve just released navigation-react-native v6.15.0. It supports scene navigation lifecycle hooks. In your Map example, you can add hooks to scene B and show and hide the map when the user navigates to and from B

useNavigated(() => {
  // Show map
});
useUnloaded(() => {
  // Hide map
});
Read more comments on GitHub >

github_iconTop Results From Across the Web

Object appearance, disappearance, and attention ... - PubMed
We examined the prioritization of abruptly appearing and disappearing objects in real-world scenes. These scene changes occurred either during a fixation ...
Read more >
Object appearance, disappearance, and attention ...
We examined the prioritization of abruptly appearing and disappearing objects in real-world scenes. These scene changes occurred either during a fixation ( ...
Read more >
Object appearance, disappearance, and attention ... - Springer
We examined the prioritization of abruptly appearing and disappearing objects in real-world scenes. These scene changes occurred either during a fixation (
Read more >
(PDF) Object appearance, disappearance, and attention ...
We examined the prioritization of abruptly appearing and disappearing objects in real-world scenes. These scene changes occurred either ...
Read more >
Detection of Appearing and Disappearing Objects in Complex ...
Our results reveal a striking difference between “appear” and “disappear” events. Listeners are remarkably tuned to object appearance: change ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found