How to use the react-native-router-flux.Actions.refresh function in react-native-router-flux

To help you get started, we’ve selected a few react-native-router-flux examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github realm / my-first-realm-app / react-native / QueryBasedSync / ToDo / src / components / ProjectList.js View on Github external
componentDidMount() {
    const { realm } = this.props;

    // Register an action to create a project
    Actions.refresh({
      rightTitle: " Create",
      onRight: () => {
        this.toggleModal();
      }
    });

    // Get a result containing all projects
    const projects = realm
      .objects("Project")
      .filtered("owner == $0", this.props.user.identity)
      .sorted("timestamp", true);

    // When the list of projects change, React won't know about it because the Result object itself did not change.
    projects.addListener(() => {
      // Bump a data version counter that we'll pass to components that should update when the projects change.
      this.setState({ dataVersion: this.state.dataVersion + 1 });
github imWildCat / wetoo / src / components / pages / User / index.js View on Github external
github = HTMLHelper.v2SocialElement2Object(getSocialElement('GitHub'));
        twitter = HTMLHelper.v2SocialElement2Object(getSocialElement('Twitter'));
        dribbble = HTMLHelper.v2SocialElement2Object(getSocialElement('Dribbble'));
        instagram = HTMLHelper.v2SocialElement2Object(getSocialElement('Instagram'));

        console.log({
          username, signature, company, position,
          avatarURI, num, regDate, liveness,
          github, twitter, dribbble, instagram,
        });
        this.setState({
          username, signature, company, position,
          avatarURI, num, regDate, liveness,
          github, twitter, dribbble, instagram,
        });
        Actions.refresh({ title: username });
      });
  }
github CarGuo / GSYGithubAPP / app / components / RepositoryDetailPage.js View on Github external
.then((res) => {
                    if (res && res.result) {
                        this.setState({
                            dataDetail: res.data
                        });
                        Actions.refresh({titleData: res.data});
                        repositoryActions.addRepositoryLocalRead(this.props.ownerName, this.props.repositoryName, res.data);
                    }
                });
            this._refresh();
github EdgeApp / edge-react-gui / src / components / scenes / PluginViewYAOBScene.js View on Github external
_renderTitle = title => {
    Actions.refresh({
      renderTitle: (
        
      )
    })
  }
github CarGuo / GSYGithubAPP / app / utils / actionUtils.js View on Github external
const selectLanguage = (lang, langName) => {
    AsyncStorage.setItem(Constant.LANGUAGE_SELECT, lang);
    AsyncStorage.setItem(Constant.LANGUAGE_SELECT_NAME, langName);
    changeLocale(lang);
    Actions.refresh();
};
github ianlancaster / react-native-web-quickstart / App / Native / Navigation / NavItems / NavItems.component.js View on Github external
const openDrawer = () => {
  NavigationActions.refresh({
    key: 'drawer',
    open: true
  })
}
github imWildCat / wetoo / src / components / pages / NewTopic / index.js View on Github external
setUpNavigationBar = () => {
    Actions.refresh({
      rightTitle: '发布',
      onRight: this.onRightButtonPress,
      rightButtonTextStyle: { color: 'white' },
    });
  };
github aksonov / react-native-router-flux / examples / react-native / components / TabView.js View on Github external
this.setState(prevState => ({ hideTabBar: !prevState.hideTabBar }), () => {
      Actions.refresh({
        hideTabBar: this.state.hideTabBar,
      }, 'tab_2');
    });
  };