import React from 'react';

import {AuthContext} from './authentication';
import NavigationBar from './tabs';
import Onboarding from './onboarding';

const Routes: React.FC = () => {
  const {
    user: {userId},
  } = React.useContext(AuthContext);
  return userId ? <NavigationBar /> : <Onboarding />;
};

export default Routes;
