You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
spa_instat_tv/src/helpers/getProfileUrl/index.tsx

20 lines
322 B

import {
SportTypes,
ProfileTypes,
SPORT_NAMES,
PROFILE_NAMES,
} from 'config'
type Args = {
id: number,
profileType: ProfileTypes,
sportType: SportTypes,
}
export const getProfileUrl = ({
id,
profileType,
sportType,
}: Args) => (
`/${SPORT_NAMES[sportType]}/${PROFILE_NAMES[profileType]}/${id}`
)