{"action":"created","issue":{"url":"https://api.github.com/repos/katspaugh/tj-mode/issues/7","labels_url":"https://api.github.com/repos/katspaugh/tj-mode/issues/7/labels{/name}","comments_url":"https://api.github.com/repos/katspaugh/tj-mode/issues/7/comments","events_url":"https://api.github.com/repos/katspaugh/tj-mode/issues/7/events","html_url":"https://github.com/katspaugh/tj-mode/issues/7","id":103232637,"number":7,"title":"Feedback","user":{"login":"angelozerr","id":1932211,"avatar_url":"https://avatars.githubusercontent.com/u/1932211?v=3","gravatar_id":"","url":"https://api.github.com/users/angelozerr","html_url":"https://github.com/angelozerr","followers_url":"https://api.github.com/users/angelozerr/followers","following_url":"https://api.github.com/users/angelozerr/following{/other_user}","gists_url":"https://api.github.com/users/angelozerr/gists{/gist_id}","starred_url":"https://api.github.com/users/angelozerr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/angelozerr/subscriptions","organizations_url":"https://api.github.com/users/angelozerr/orgs","repos_url":"https://api.github.com/users/angelozerr/repos","events_url":"https://api.github.com/users/angelozerr/events{/privacy}","received_events_url":"https://api.github.com/users/angelozerr/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-08-26T10:31:17Z","updated_at":"2015-08-26T10:40:23Z","closed_at":null,"body":"@katspaugh I have started to integrate your higlight tern plugin inside Eclipse but I had several problems and I had to modify your code in order to it works for Eclipse. \r\n\r\nI have 2 choices : \r\n * use your tern plugin if you accept my changes.\r\n * create my own tern plugin (very shame -())\r\n\r\nThe first thing which is very important is the performance (with big files). With your tern plugin I have a big problems with performance because you need to post tern file before calling your query \"higlight\". This post of tern file execute the analyse of the tern file each time you are typing, which is a problem for performance. \r\n\r\nIndeed, with you tern plugin, you must post tern file and call after your \"higlight\" tern query which loops for each posted tern files (why a loop?, highlight is just for a given file, no?).\r\n\r\nMy change is that I set the text content in the query to avoid posting tern file:\r\n\r\n * pros : provide a very good performance\r\n * cons: you loose information of the type like your Error/Warning message (with Identifier which uses expressionType).\r\n\r\nBut IMHO, Highlight must be just higlight tokens and not manage validation. Validation must be done with other linter like tern-lint or https://github.com/marijnh/blint which is based on acorn too.\r\n\r\nIf you are OK with my suggestion (not to use tern file, but just set the text file content in the query), I will create a PR. \r\n\r\nI hope you will be OK, because I have improved your higlight to higlight even if js code is not valid like : \r\n\r\n```javascript\r\nvar \r\nvar a = 10 // here highlight doesn't work because teh first var breaks acorn parser.\r\n```\r\n\r\nI would like to provide ES6 higlight features. Hope we will able to work together."},"comment":{"url":"https://api.github.com/repos/katspaugh/tj-mode/issues/comments/134940621","html_url":"https://github.com/katspaugh/tj-mode/issues/7#issuecomment-134940621","issue_url":"https://api.github.com/repos/katspaugh/tj-mode/issues/7","id":134940621,"user":{"login":"katspaugh","id":381895,"avatar_url":"https://avatars.githubusercontent.com/u/381895?v=3","gravatar_id":"","url":"https://api.github.com/users/katspaugh","html_url":"https://github.com/katspaugh","followers_url":"https://api.github.com/users/katspaugh/followers","following_url":"https://api.github.com/users/katspaugh/following{/other_user}","gists_url":"https://api.github.com/users/katspaugh/gists{/gist_id}","starred_url":"https://api.github.com/users/katspaugh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/katspaugh/subscriptions","organizations_url":"https://api.github.com/users/katspaugh/orgs","repos_url":"https://api.github.com/users/katspaugh/repos","events_url":"https://api.github.com/users/katspaugh/events{/privacy}","received_events_url":"https://api.github.com/users/katspaugh/received_events","type":"User","site_admin":false},"created_at":"2015-08-26T10:40:23Z","updated_at":"2015-08-26T10:40:23Z","body":"I'm fine with moving out undefined variables linting out of the plugin. Simple syntax checks should still be there, I think.\r\n\r\n> I have improved your higlight to higlight even if js code is not valid like :\r\n\r\nI actually think this is an anti-feature :) If the syntax is invalid why should it be highlighted?\r\n\r\nAnyway, I would be happy to review your PR. Thanks!"}}