{"action":"created","issue":{"url":"https://api.github.com/repos/fxbois/web-mode/issues/415","labels_url":"https://api.github.com/repos/fxbois/web-mode/issues/415/labels{/name}","comments_url":"https://api.github.com/repos/fxbois/web-mode/issues/415/comments","events_url":"https://api.github.com/repos/fxbois/web-mode/issues/415/events","html_url":"https://github.com/fxbois/web-mode/issues/415","id":55716155,"number":415,"title":"cannnot indent correctly in js.erb","user":{"login":"Ryohe","id":10287091,"avatar_url":"https://avatars.githubusercontent.com/u/10287091?v=3","gravatar_id":"","url":"https://api.github.com/users/Ryohe","html_url":"https://github.com/Ryohe","followers_url":"https://api.github.com/users/Ryohe/followers","following_url":"https://api.github.com/users/Ryohe/following{/other_user}","gists_url":"https://api.github.com/users/Ryohe/gists{/gist_id}","starred_url":"https://api.github.com/users/Ryohe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ryohe/subscriptions","organizations_url":"https://api.github.com/users/Ryohe/orgs","repos_url":"https://api.github.com/users/Ryohe/repos","events_url":"https://api.github.com/users/Ryohe/events{/privacy}","received_events_url":"https://api.github.com/users/Ryohe/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-01-28T05:28:07Z","updated_at":"2015-01-28T12:17:12Z","closed_at":null,"body":"Hi. At first, I hope my poor english let you understand...\r\n\r\nI'm using web-mode 10.3.05 and emacs 24.3.1.\r\nmy emacs on web-mode, following source code (example in your page) cannnot do correctly indentaion.\r\n\r\n`<ul>`\r\n`<% for @item in @items -%>`\r\n`<li><%= @item %></li>`\r\n`<% end %>`\r\n`</ul>`\r\n\r\nin this source code, `web-mode-engine` is erb. and I indent with `indent-for-tab-command` command.\r\nmy emacs init.el is here.\r\n\r\n```lisp\r\n...\r\n;;web-mode\r\n(require 'web-mode)\r\n(add-to-list 'auto-mode-alist '(\"\\\\.js.erb\\\\'\" . web-mode))\r\n(setq web-mode-engines-alist \r\n      '((\"erb\" . \"\\\\.js.erb\\\\'\"))\r\n)\r\n(defun my-web-mode-hook () \r\n  \"Hooks for Web mode.\" \r\n  (setq web-mode-markup-indent-offset 2)\r\n  (setq web-mode-css-indent-offset 2)\r\n  (setq web-mode-code-indent-offset 2)\r\n  (setq web-mode-block-padding 2)\r\n  (setq web-mode-markup-indentation t)\r\n)\r\n(add-hook 'web-mode-hook 'my-web-mode-hook)\r\n...\r\n```\r\n\r\nthanks!\r\n"},"comment":{"url":"https://api.github.com/repos/fxbois/web-mode/issues/comments/71826224","html_url":"https://github.com/fxbois/web-mode/issues/415#issuecomment-71826224","issue_url":"https://api.github.com/repos/fxbois/web-mode/issues/415","id":71826224,"user":{"login":"Ryohe","id":10287091,"avatar_url":"https://avatars.githubusercontent.com/u/10287091?v=3","gravatar_id":"","url":"https://api.github.com/users/Ryohe","html_url":"https://github.com/Ryohe","followers_url":"https://api.github.com/users/Ryohe/followers","following_url":"https://api.github.com/users/Ryohe/following{/other_user}","gists_url":"https://api.github.com/users/Ryohe/gists{/gist_id}","starred_url":"https://api.github.com/users/Ryohe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ryohe/subscriptions","organizations_url":"https://api.github.com/users/Ryohe/orgs","repos_url":"https://api.github.com/users/Ryohe/repos","events_url":"https://api.github.com/users/Ryohe/events{/privacy}","received_events_url":"https://api.github.com/users/Ryohe/received_events","type":"User","site_admin":false},"created_at":"2015-01-28T12:17:12Z","updated_at":"2015-01-28T12:17:12Z","body":"thanks for your advice. but problem remains unchanged...\r\n\r\nI found above example shows correct indent in html.erb.\r\ni wanna do like this in js.erb, for example\r\n```javascript\r\n<% array.each do |e| %>\r\nvar x = e;\r\n<% end %>\r\n```\r\nto\r\n```javascript\r\n<% array.each do |e| %>\r\n  var x = e;\r\n<% end %>\r\n```\r\n\r\nisnt this supported?"}}