React - append string to react variable with backtick

0 votes
293 views
added Apr 12, 2021 in React by lcjr First Warrant Officer (11,530 points)
<a className="agency-url" target="_blank" href={`http://${agencyURL}`}>{agencyURL}</a>

 

1 Response

0 votes
responded Apr 14, 2021 by lcjr First Warrant Officer (11,530 points)
<a
  href={`https://mysite.com/project/${agentItemData.project_param}`}
  className="btn btn-primary"
>
  View More
</a>

 

lazacode.org - Malaysia's programming knowledge sharing platform, where everyone can share their finding as reference to others.
...