{"action":"created","issue":{"url":"https://api.github.com/repos/aframevr/aframe/issues/3681","repository_url":"https://api.github.com/repos/aframevr/aframe","labels_url":"https://api.github.com/repos/aframevr/aframe/issues/3681/labels{/name}","comments_url":"https://api.github.com/repos/aframevr/aframe/issues/3681/comments","events_url":"https://api.github.com/repos/aframevr/aframe/issues/3681/events","html_url":"https://github.com/aframevr/aframe/issues/3681","id":338083421,"node_id":"MDU6SXNzdWUzMzgwODM0MjE=","number":3681,"title":"Updating a line component using a cached THREE.Vector3 fails","user":{"login":"InfiniteLee","id":1821537,"node_id":"MDQ6VXNlcjE4MjE1Mzc=","avatar_url":"https://avatars2.githubusercontent.com/u/1821537?v=4","gravatar_id":"","url":"https://api.github.com/users/InfiniteLee","html_url":"https://github.com/InfiniteLee","followers_url":"https://api.github.com/users/InfiniteLee/followers","following_url":"https://api.github.com/users/InfiniteLee/following{/other_user}","gists_url":"https://api.github.com/users/InfiniteLee/gists{/gist_id}","starred_url":"https://api.github.com/users/InfiniteLee/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/InfiniteLee/subscriptions","organizations_url":"https://api.github.com/users/InfiniteLee/orgs","repos_url":"https://api.github.com/users/InfiniteLee/repos","events_url":"https://api.github.com/users/InfiniteLee/events{/privacy}","received_events_url":"https://api.github.com/users/InfiniteLee/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-07-03T23:20:19Z","updated_at":"2018-07-03T23:46:23Z","closed_at":null,"author_association":"NONE","body":"A `line` component will not update if using a cached `THREE.Vector3` to call `setAttribute`. I believe this is because `deepEqual` is used in component to determine if an attribute was actually updated or not. As such, this probably affects other components that similarly allow (or at least don't explicitly disallow) the use of THREE vectors. \r\n\r\nAside from updating the `deepEqual` method, another option may be to allow forcing an update via another attribute like `needsUpdate`. \r\n\r\n```\r\n        init() {\r\n          this.end = new THREE.Vector3();\r\n        },\r\n        \r\n        tick() {\r\n          this.end.set(Math.random(),  Math.random(),  Math.random());\r\n          this.el.setAttribute(\"line\", {end: this.end}); //will not update after the first tick\r\n        }\r\n```\r\n- A-Frame Version: 0.8.2\r\n- Platform / Device: any\r\n- Reproducible Code Snippet or URL: https://glitch.com/edit/#!/heavenly-piranha\r\n"},"comment":{"url":"https://api.github.com/repos/aframevr/aframe/issues/comments/402322413","html_url":"https://github.com/aframevr/aframe/issues/3681#issuecomment-402322413","issue_url":"https://api.github.com/repos/aframevr/aframe/issues/3681","id":402322413,"node_id":"MDEyOklzc3VlQ29tbWVudDQwMjMyMjQxMw==","user":{"login":"ngokevin","id":674727,"node_id":"MDQ6VXNlcjY3NDcyNw==","avatar_url":"https://avatars2.githubusercontent.com/u/674727?v=4","gravatar_id":"","url":"https://api.github.com/users/ngokevin","html_url":"https://github.com/ngokevin","followers_url":"https://api.github.com/users/ngokevin/followers","following_url":"https://api.github.com/users/ngokevin/following{/other_user}","gists_url":"https://api.github.com/users/ngokevin/gists{/gist_id}","starred_url":"https://api.github.com/users/ngokevin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ngokevin/subscriptions","organizations_url":"https://api.github.com/users/ngokevin/orgs","repos_url":"https://api.github.com/users/ngokevin/repos","events_url":"https://api.github.com/users/ngokevin/events{/privacy}","received_events_url":"https://api.github.com/users/ngokevin/received_events","type":"User","site_admin":false},"created_at":"2018-07-03T23:46:23Z","updated_at":"2018-07-03T23:46:23Z","author_association":"MEMBER","body":"Yeah, unless we refactor the system and have some sort of forced dirty flag, they can't be updated with the same object.\r\n\r\nAn alternative is to flip-flop between two vector objects as you update."}}
{"actor":{"display_login":"ngokevin"}}