Revert #12461 -- add salt_data kwarg instead

After testing by @jasonrm the previous refactor in 1525f211 didn't quite
work as expected, so I've reverted those changes and instead have added
a new kwarg to the render function that will control if the function
returns salt data or the composed scope for reuse elsewhere.
Merge pull request #12477 from borgstrom/revert_12461

Revert #12461 -- add salt_data kwarg instead