Menu
Hi all. I’m kinda new to js so thank you in advance for your help.
I have a bit of function like this:
render() {
return (
<div className=”Account>
</div>
);
}
I would like to add a function within the div but when I put the function in it just prints the code as text.
render() {
return (
<div className=”Account>
printBalance();
</div>
);
}
printBalance() {
return “Your balance is…”;
}
How do I differentiate the tags and code in this case? I’m not even sure why the raw html works well in that render. Can anyone enlighten me as to how best (practice) accomplish what I need?
Thanks
bluprint