simple javascript template engine