M4 templating language in pure Javascript