Revert to previous compile_dir functionality (fixes #148)

The backward incompatible change introduced in commit
0b61b69591f60a427d65faa95c00119e23edad09 is reverted, and instead a
new `render` function is added for those who wish to get the tagged
result tuple `{ok, iolist()} | {error, Reason}`.