Let's say that I have a function called Foo() which outputs "Hello world!", and I want to make a function called Bar() which takes the output of Foo() and bolds it. Desired output:
Hello world!
Things I have tried:
function Bar() {
return <b>Foo()</b>;
}
Output: Foo()
function Bar() {
var f = <b>Foo()</b>;
return f;
}
Output: Foo()
function Bar() {
var f = Foo();
return <b>f</b>;
}
Output: f
function Bar() {
return "<b>" + Foo() + "</b>";
}
Output: <b>[object Object]</b>
What do I need to do to get Hello world! as the output?