how to concatenate a string with a variable's value in javascript (more specifically react).In this ToolsCard component, I am getting the title as prop and I want to make a string 'download title which is being received as prop, how should I do this.I tried the below way but I am getting an error, Is there some alternative to do this?
const ToolsCard = ({title}) => {
const str='download'+{title}
}
const ToolsCard = title => 'download ' + title;
I don't know what else to tell you. You might want to export the ToolsCard function maybe. And you should definitely read some Javascript and React tutorials.