How to assign a return value from a function directly to an object literal
<p>I have the following code:</p>

<p>"myFunction" is an anonymous function that I have got as a parameter.
...</p>

<pre><code>newObj = { id: idValue, div: null };
newObj.div = myFunction();
</code></pre>

<p>Is there a shorter way, a way to directly assign the result of a function to the object literal, something like:</p>

<pre><code>newObj = { id: idValue, div: (myFunction ())};
</code></pre>

<p>Thanks alot in advance
Wolfgang</p>
