{"action":"created","issue":{"url":"https://api.github.com/repos/facebook/react/issues/1931","labels_url":"https://api.github.com/repos/facebook/react/issues/1931/labels{/name}","comments_url":"https://api.github.com/repos/facebook/react/issues/1931/comments","events_url":"https://api.github.com/repos/facebook/react/issues/1931/events","html_url":"https://github.com/facebook/react/issues/1931","id":38751908,"number":1931,"title":"Perf.printWasted prints newly inserted dom nodes in list as a waste of time","user":{"login":"slorber","id":749374,"avatar_url":"https://avatars.githubusercontent.com/u/749374?v=3","gravatar_id":"","url":"https://api.github.com/users/slorber","html_url":"https://github.com/slorber","followers_url":"https://api.github.com/users/slorber/followers","following_url":"https://api.github.com/users/slorber/following{/other_user}","gists_url":"https://api.github.com/users/slorber/gists{/gist_id}","starred_url":"https://api.github.com/users/slorber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/slorber/subscriptions","organizations_url":"https://api.github.com/users/slorber/orgs","repos_url":"https://api.github.com/users/slorber/repos","events_url":"https://api.github.com/users/slorber/events{/privacy}","received_events_url":"https://api.github.com/users/slorber/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/facebook/react/labels/Component:%20Addons%20/%20Perf","name":"Component: Addons / Perf","color":"e11d21"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":10,"created_at":"2014-07-25T17:22:23Z","updated_at":"2015-07-29T06:29:00Z","closed_at":null,"body":"\r\n\r\nFirst of all, during my attempt to show you this bug, I found this weird behavior:\r\n\r\n1) http://jsfiddle.net/kb3gN/4092/ does not show any time wasted (on user click action)\r\n2) http://jsfiddle.net/kb3gN/4093/ does\r\nI don't know why one does show wasted time and not the other\r\n\r\nOn 2) I use shouldComponentUpdate=true, and we can see the time waste grows with the list size as well as the number of instances in the table.\r\n\r\n\r\n\r\nSo finally, to demonstrate my problem, see http://jsfiddle.net/kb3gN/4094/\r\nI've implemented correctly shouldComponentUpdate and now each time I add a new element in the list, it is considered as a waste of time. My table always show 1 instance: the one that just got inserted.\r\n\r\n\r\nI've had this problem on my app, when dealing with a paginated list (loading more items from the server as the user scrolls down). I don't think this newly inserted node should be printed in `printWasted` "},"comment":{"url":"https://api.github.com/repos/facebook/react/issues/comments/125854997","html_url":"https://github.com/facebook/react/issues/1931#issuecomment-125854997","issue_url":"https://api.github.com/repos/facebook/react/issues/1931","id":125854997,"user":{"login":"JaeHunRo","id":8787226,"avatar_url":"https://avatars.githubusercontent.com/u/8787226?v=3","gravatar_id":"","url":"https://api.github.com/users/JaeHunRo","html_url":"https://github.com/JaeHunRo","followers_url":"https://api.github.com/users/JaeHunRo/followers","following_url":"https://api.github.com/users/JaeHunRo/following{/other_user}","gists_url":"https://api.github.com/users/JaeHunRo/gists{/gist_id}","starred_url":"https://api.github.com/users/JaeHunRo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JaeHunRo/subscriptions","organizations_url":"https://api.github.com/users/JaeHunRo/orgs","repos_url":"https://api.github.com/users/JaeHunRo/repos","events_url":"https://api.github.com/users/JaeHunRo/events{/privacy}","received_events_url":"https://api.github.com/users/JaeHunRo/received_events","type":"User","site_admin":false},"created_at":"2015-07-29T06:29:00Z","updated_at":"2015-07-29T06:29:00Z","body":"Was this ever resolved? React.addons.Perf is still behaving similarly with newly inserted dom nodes being printed as wasted time. Also, @koba04 could I get some clarity on why the first fiddle prints wasted time but the second does not?"}}