Exporting sourcemaps

Fixes #30
This looks odd – is it really needed to insert an empty transaction in this way. I do not think this whole code here is needed..