BlueWallet/NavigationService.js

13 lines
298 B
JavaScript
Raw Normal View History

/* eslint-disable no-unused-expressions */
import * as React from 'react';
2019-01-24 08:36:01 +01:00
export const navigationRef = React.createRef();
2019-01-24 08:36:01 +01:00
export function navigate(name, params) {
navigationRef.current?.navigate(name, params);
2019-01-24 08:36:01 +01:00
}
export function dispatch(params) {
navigationRef.current?.dispatch(params);
2019-01-24 08:36:01 +01:00
}