{"action":"opened","issue":{"url":"https://api.github.com/repos/yeoman/generator/issues/804","labels_url":"https://api.github.com/repos/yeoman/generator/issues/804/labels{/name}","comments_url":"https://api.github.com/repos/yeoman/generator/issues/804/comments","events_url":"https://api.github.com/repos/yeoman/generator/issues/804/events","html_url":"https://github.com/yeoman/generator/issues/804","id":73113444,"number":804,"title":"Switch underscore.template to ejs/handlebar","user":{"login":"yangchenyun","id":1043403,"avatar_url":"https://avatars.githubusercontent.com/u/1043403?v=3","gravatar_id":"","url":"https://api.github.com/users/yangchenyun","html_url":"https://github.com/yangchenyun","followers_url":"https://api.github.com/users/yangchenyun/followers","following_url":"https://api.github.com/users/yangchenyun/following{/other_user}","gists_url":"https://api.github.com/users/yangchenyun/gists{/gist_id}","starred_url":"https://api.github.com/users/yangchenyun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yangchenyun/subscriptions","organizations_url":"https://api.github.com/users/yangchenyun/orgs","repos_url":"https://api.github.com/users/yangchenyun/repos","events_url":"https://api.github.com/users/yangchenyun/events{/privacy}","received_events_url":"https://api.github.com/users/yangchenyun/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-05-04T20:00:01Z","updated_at":"2015-05-04T20:00:01Z","closed_at":null,"body":"Hi Yeoman team,\r\n     Thanks for the work of yeoman! I've migrated some codegen tool into yeoman framework, and it is a pleasure to do so. \r\n     After some development in yeoman, I found the template engine (underscore.template) lacks some important feature to write a template in maintainable format while output right format target file:\r\n\r\n     - Lack of whitespace controls.   Underscore's engine is by nature string replacement, thus it lacks precise whitespace controls which you will find in modern template engine such as [jinja2](http://jinja.pocoo.org/docs/dev/templates/#whitespace-control), [handlebar](http://handlebarsjs.com/expressions.html#whitespace-control).  Missing of this feature makes it is very [hack-y](http://stackoverflow.com/questions/13169885/underscorejs-removing-unwanted-spaces-for-logic-part/13170456#13170456) to get the output right.  For a complex template, it means less maintainable source code. \r\n   \r\n     - Lack of raw output. Through, it is possible to configure the engine to use other keywords then \"<%=\", \"<%\" as syntax; it doesn't avoid the problem to output these syntax as raw string instead of interpreting them as source code. \r\n\r\n     So I suggest a switch from underscore.template to a real template engine such as ejs / handlebar.\r\n\r\nBest,\r\n "}}