At the moment, I am trying to list projects on a website in a grid. Some of them link to another page on the site and others link to another domain page. At the moment I am using React-Router's 'Link' to go from one page to another, however this doesn't work when going to a page outside of the domain. In the JSON file, I check for the 'url' variable which returns either the URL if its public or 'project-page' if it is local. I can't figure out how to differentiate between the two in JSX; is there a work around while still utilizing the JSON file?
<div className="projects">
    {projectData.map((projectDetail, index) => {
        return(
            <div className='project-card'>
                <Link to={projectDetail.url}>
                    <img src={require('./images/icons/' + projectDetail.alt + '.jpg')} alt={projectDetail.title}/>
                    <h3>{projectDetail.title}</h3>
                    <p>{projectDetail.subtext}</p>
                </Link>
            </div>
        )
    })}
</div>
 
     
    