{"action":"created","issue":{"url":"https://api.github.com/repos/Valloric/ycmd/issues/272","labels_url":"https://api.github.com/repos/Valloric/ycmd/issues/272/labels{/name}","comments_url":"https://api.github.com/repos/Valloric/ycmd/issues/272/comments","events_url":"https://api.github.com/repos/Valloric/ycmd/issues/272/events","html_url":"https://github.com/Valloric/ycmd/pull/272","id":121867838,"number":272,"title":"[RFC] JavaScript completer using Tern.js","user":{"login":"puremourning","id":10584846,"avatar_url":"https://avatars.githubusercontent.com/u/10584846?v=3","gravatar_id":"","url":"https://api.github.com/users/puremourning","html_url":"https://github.com/puremourning","followers_url":"https://api.github.com/users/puremourning/followers","following_url":"https://api.github.com/users/puremourning/following{/other_user}","gists_url":"https://api.github.com/users/puremourning/gists{/gist_id}","starred_url":"https://api.github.com/users/puremourning/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/puremourning/subscriptions","organizations_url":"https://api.github.com/users/puremourning/orgs","repos_url":"https://api.github.com/users/puremourning/repos","events_url":"https://api.github.com/users/puremourning/events{/privacy}","received_events_url":"https://api.github.com/users/puremourning/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":37,"created_at":"2015-12-12T17:31:31Z","updated_at":"2015-12-13T17:36:47Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/Valloric/ycmd/pulls/272","html_url":"https://github.com/Valloric/ycmd/pull/272","diff_url":"https://github.com/Valloric/ycmd/pull/272.diff","patch_url":"https://github.com/Valloric/ycmd/pull/272.patch"},"body":"# Overview\r\n\r\nAdds support for a JavaScript completer using [Tern.js](http://ternjs.net).\r\n\r\nThe completer supports:\r\n\r\n* Intelligent auto-completion\r\n* Go to definition, references (`GoTo`, etc.)\r\n* Semantic type information for identifiers (`GetType`)\r\n* View documentation comments for identifiers (`GetDoc`)\r\n* Management of `tern` server instance\r\n\r\nThis provides (for Vim at least) a replacement, for [tern_for_vim](https://github.com/ternjs/tern_for_vim) automagically in ycmd.\r\n\r\n## Demo\r\n\r\nCompletions:\r\n\r\n![ycm-tern-demo](https://cloud.githubusercontent.com/assets/10584846/11763113/035f748c-a0f6-11e5-8961-77139d4e6f45.gif)\r\n\r\nSubcommands:\r\n\r\n![ycm-tern-demo-subcommands](https://cloud.githubusercontent.com/assets/10584846/11763115/0523467c-a0f6-11e5-8552-357bcdda2e6a.gif)\r\n\r\n## Installation\r\n\r\nRun `install.py --tern-completer`\r\n\r\n## Caveats and differences vs. tern_for_vim\r\n\r\n* Currently, to use it there must be a `.tern-project` configuration file somewhere in the directory tree above Vim's working directory when the first JavaScript file is opened (i.e. when the server starts). I believe this is also true for `tern_for_vim`. \r\n* Does not support refactoring (rename) which `tern_for_vim` does\r\n* Methods from `Object.prototype` are always included. Tern has the ability to only include them when they match some number of typed characters, as they are otherwise \"noise\". This is incompatible with ycmd's cache and LCS matching.\r\n\r\n## Status\r\n\r\nI believe this to be fully working with the above caveats. I think the first one is the most frustrating, but it isn't obvious how to avoid it.\n\n<!-- Reviewable:start -->\n[<img src=\"https://reviewable.io/review_button.png\" height=40 alt=\"Review on Reviewable\"/>](https://reviewable.io/reviews/valloric/ycmd/272)\n<!-- Reviewable:end -->\n"},"comment":{"url":"https://api.github.com/repos/Valloric/ycmd/issues/comments/164279359","html_url":"https://github.com/Valloric/ycmd/pull/272#issuecomment-164279359","issue_url":"https://api.github.com/repos/Valloric/ycmd/issues/272","id":164279359,"user":{"login":"puremourning","id":10584846,"avatar_url":"https://avatars.githubusercontent.com/u/10584846?v=3","gravatar_id":"","url":"https://api.github.com/users/puremourning","html_url":"https://github.com/puremourning","followers_url":"https://api.github.com/users/puremourning/followers","following_url":"https://api.github.com/users/puremourning/following{/other_user}","gists_url":"https://api.github.com/users/puremourning/gists{/gist_id}","starred_url":"https://api.github.com/users/puremourning/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/puremourning/subscriptions","organizations_url":"https://api.github.com/users/puremourning/orgs","repos_url":"https://api.github.com/users/puremourning/repos","events_url":"https://api.github.com/users/puremourning/events{/privacy}","received_events_url":"https://api.github.com/users/puremourning/received_events","type":"User","site_admin":false},"created_at":"2015-12-13T17:36:47Z","updated_at":"2015-12-13T17:36:47Z","body":"\n\n\n\nReview status: all files reviewed at latest revision, 6 unresolved discussions.\n\n---\n\n*[build.py, line 30 \\[r3\\]](https://reviewable.io:443/reviews/valloric/ycmd/272#-K5R8NL0K8v2kxGIO5_a:-K5RPTeZUfLMY3HAG1EV:-985529118) ([raw file](https://github.com/valloric/ycmd/blob/0abbf2d9481d4e7e805c68837a73d0c413377738/build.py#L30)):*\nI decoupled them. Still not a fan of the duplication, but not having the coupling means build.py is likely to work on more systems, which means fewer entries on the tracker, which means less pain.\n\n---\n\n\n*Comments from the [review on Reviewable.io](https://reviewable.io:443/reviews/valloric/ycmd/272)*\n<!-- Sent from Reviewable.io -->\n"}}