import React from 'react'; import { NavLink } from 'react-router-dom'; import './AsideMenu.scss'; export default function AsideMenu({ selectedServer }) { const serverId = selectedServer ? selectedServer.id : ''; const isListShortUrlsActive = (match, { pathname }) => { // FIXME. Should use the 'match' params, but they are not being properly resolved. Investigate const serverIdFromPathname = pathname.split('/')[2]; return serverIdFromPathname === serverId && pathname.indexOf('list-short-urls') !== -1; }; return ( ); }