{"action":"created","issue":{"url":"https://api.github.com/repos/ntrupin/LineScript/issues/23","repository_url":"https://api.github.com/repos/ntrupin/LineScript","labels_url":"https://api.github.com/repos/ntrupin/LineScript/issues/23/labels{/name}","comments_url":"https://api.github.com/repos/ntrupin/LineScript/issues/23/comments","events_url":"https://api.github.com/repos/ntrupin/LineScript/issues/23/events","html_url":"https://github.com/ntrupin/LineScript/issues/23","id":354379438,"node_id":"MDU6SXNzdWUzNTQzNzk0Mzg=","number":23,"title":"remove output variable ","user":{"login":"Yamboy1","id":37413895,"node_id":"MDQ6VXNlcjM3NDEzODk1","avatar_url":"https://avatars2.githubusercontent.com/u/37413895?v=4","gravatar_id":"","url":"https://api.github.com/users/Yamboy1","html_url":"https://github.com/Yamboy1","followers_url":"https://api.github.com/users/Yamboy1/followers","following_url":"https://api.github.com/users/Yamboy1/following{/other_user}","gists_url":"https://api.github.com/users/Yamboy1/gists{/gist_id}","starred_url":"https://api.github.com/users/Yamboy1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yamboy1/subscriptions","organizations_url":"https://api.github.com/users/Yamboy1/orgs","repos_url":"https://api.github.com/users/Yamboy1/repos","events_url":"https://api.github.com/users/Yamboy1/events{/privacy}","received_events_url":"https://api.github.com/users/Yamboy1/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-08-27T16:05:18Z","updated_at":"2018-08-27T16:49:27Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"This might be a bit down to preference, but I think that you should remove the output variable, from compiler.js, and instead, have the parse function return the output value. Considering the fact that you already have a return statement in the code for each case, all this should require on compiler.js, is to change\n```js\noutput = `<${tagname} ${v[1]}>${c[1]}</${tagname}>`\nreturn output;\n```\nto\n```js\nreturn `<${tagname} ${v[1]}>${c[1]}</${tagname}>`\n```\nand then, in gate.js, rather than saying\n```js\nparse(ele)\n```\nyou'd have\n```js\nconst output = parse(ele)\n```\nThis is more explicit about what the variables is, and it makes more sense straight away, without having to think about where the output variable came from, and what it is. Plus using global variables in the way that you currently are, is generally frowned upon by most of  the js community. \n "},"comment":{"url":"https://api.github.com/repos/ntrupin/LineScript/issues/comments/416290659","html_url":"https://github.com/ntrupin/LineScript/issues/23#issuecomment-416290659","issue_url":"https://api.github.com/repos/ntrupin/LineScript/issues/23","id":416290659,"node_id":"MDEyOklzc3VlQ29tbWVudDQxNjI5MDY1OQ==","user":{"login":"Yamboy1","id":37413895,"node_id":"MDQ6VXNlcjM3NDEzODk1","avatar_url":"https://avatars2.githubusercontent.com/u/37413895?v=4","gravatar_id":"","url":"https://api.github.com/users/Yamboy1","html_url":"https://github.com/Yamboy1","followers_url":"https://api.github.com/users/Yamboy1/followers","following_url":"https://api.github.com/users/Yamboy1/following{/other_user}","gists_url":"https://api.github.com/users/Yamboy1/gists{/gist_id}","starred_url":"https://api.github.com/users/Yamboy1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yamboy1/subscriptions","organizations_url":"https://api.github.com/users/Yamboy1/orgs","repos_url":"https://api.github.com/users/Yamboy1/repos","events_url":"https://api.github.com/users/Yamboy1/events{/privacy}","received_events_url":"https://api.github.com/users/Yamboy1/received_events","type":"User","site_admin":false},"created_at":"2018-08-27T16:49:27Z","updated_at":"2018-08-27T16:49:27Z","author_association":"CONTRIBUTOR","body":"sure, I can do it "}}
{"actor":{"display_login":"Yamboy1"}}