This topic was automatically generated from Slack. You can find the original thread here.
In a node.js file - What are the pro and cons or use cases of using $.export
vs. return
?
This topic was automatically generated from Slack. You can find the original thread here.
In a node.js file - What are the pro and cons or use cases of using $.export
vs. return
?
return
is final. It sends execution and you can’t run additional code that populates additional properties.
$.export
allows you to conditionally add properties and continue execution