{"action":"created","comment":{"url":"https://api.github.com/repos/nfl/react-helmet/pulls/comments/38344268","id":38344268,"diff_hunk":"@@ -628,5 +629,37 @@ describe(\"Helmet\", () => {\n \n             Helmet.canUseDOM = true;\n         });\n+\n+        it(\"will not update the DOM if updated props are unchanged\", (done) => {\n+            const old = HelmetUnwrapped.onDOMChange;\n+            let changesToDOM = 0;\n+            HelmetUnwrapped.onDOMChange = (state) => {\n+                changesToDOM++;\n+                return state;\n+            };\n+\n+            React.render(\n+                <Helmet\n+                    title={\"Test Title\"}\n+                    meta={[{\"name\": \"description\", \"content\": \"Test description\"}]}\n+                />,\n+                container\n+            );\n+\n+            // Re-rendering will pass new props to an already mounted Helmet\n+            React.render(\n+                <Helmet\n+                    title={\"Test Title\"}\n+                    meta={[{\"name\": \"description\", \"content\": \"Test description\"}]}\n+                />,\n+                container\n+            );\n+\n+            setTimeout(() => {\n+                expect(changesToDOM).to.equal(1);\n+                HelmetUnwrapped.onDOMChange = old;\n+                done();\n+            }, 1000);\n+        });","path":"src/test/HelmetTest.jsx","position":43,"original_position":43,"commit_id":"9f2897d98fb399bdfb64903b1921d1637927b097","original_commit_id":"9f2897d98fb399bdfb64903b1921d1637927b097","user":{"login":"cwelch5","id":2126424,"avatar_url":"https://avatars.githubusercontent.com/u/2126424?v=3","gravatar_id":"","url":"https://api.github.com/users/cwelch5","html_url":"https://github.com/cwelch5","followers_url":"https://api.github.com/users/cwelch5/followers","following_url":"https://api.github.com/users/cwelch5/following{/other_user}","gists_url":"https://api.github.com/users/cwelch5/gists{/gist_id}","starred_url":"https://api.github.com/users/cwelch5/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cwelch5/subscriptions","organizations_url":"https://api.github.com/users/cwelch5/orgs","repos_url":"https://api.github.com/users/cwelch5/repos","events_url":"https://api.github.com/users/cwelch5/events{/privacy}","received_events_url":"https://api.github.com/users/cwelch5/received_events","type":"User","site_admin":false},"body":"Sure.","created_at":"2015-08-31T18:40:40Z","updated_at":"2015-08-31T18:40:40Z","html_url":"https://github.com/nfl/react-helmet/pull/37#discussion_r38344268","pull_request_url":"https://api.github.com/repos/nfl/react-helmet/pulls/37","_links":{"self":{"href":"https://api.github.com/repos/nfl/react-helmet/pulls/comments/38344268"},"html":{"href":"https://github.com/nfl/react-helmet/pull/37#discussion_r38344268"},"pull_request":{"href":"https://api.github.com/repos/nfl/react-helmet/pulls/37"}}},"pull_request":{"url":"https://api.github.com/repos/nfl/react-helmet/pulls/37","id":43708377,"html_url":"https://github.com/nfl/react-helmet/pull/37","diff_url":"https://github.com/nfl/react-helmet/pull/37.diff","patch_url":"https://github.com/nfl/react-helmet/pull/37.patch","issue_url":"https://api.github.com/repos/nfl/react-helmet/issues/37","number":37,"state":"open","locked":false,"title":"handleClientStateChange does deep-equal check to prevent unnecessary …","user":{"login":"cwelch5","id":2126424,"avatar_url":"https://avatars.githubusercontent.com/u/2126424?v=3","gravatar_id":"","url":"https://api.github.com/users/cwelch5","html_url":"https://github.com/cwelch5","followers_url":"https://api.github.com/users/cwelch5/followers","following_url":"https://api.github.com/users/cwelch5/following{/other_user}","gists_url":"https://api.github.com/users/cwelch5/gists{/gist_id}","starred_url":"https://api.github.com/users/cwelch5/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cwelch5/subscriptions","organizations_url":"https://api.github.com/users/cwelch5/orgs","repos_url":"https://api.github.com/users/cwelch5/repos","events_url":"https://api.github.com/users/cwelch5/events{/privacy}","received_events_url":"https://api.github.com/users/cwelch5/received_events","type":"User","site_admin":false},"body":"…DOM changes\r\n\r\nAlso added deep-equal check to Helmet to prevent unnecessary re-renders.\r\nUpdated unit tests to check for DOM Changes, utilizing new static onDOMChange function added to Helmet.","created_at":"2015-08-30T06:20:54Z","updated_at":"2015-08-31T18:40:40Z","closed_at":null,"merged_at":null,"merge_commit_sha":"060cb096f2a9f46a7d9e33f1d00e2a9b5ffa6697","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/nfl/react-helmet/pulls/37/commits","review_comments_url":"https://api.github.com/repos/nfl/react-helmet/pulls/37/comments","review_comment_url":"https://api.github.com/repos/nfl/react-helmet/pulls/comments{/number}","comments_url":"https://api.github.com/repos/nfl/react-helmet/issues/37/comments","statuses_url":"https://api.github.com/repos/nfl/react-helmet/statuses/9f2897d98fb399bdfb64903b1921d1637927b097","head":{"label":"nfl:feature/limitDOMChanges","ref":"feature/limitDOMChanges","sha":"9f2897d98fb399bdfb64903b1921d1637927b097","user":{"login":"nfl","id":1261928,"avatar_url":"https://avatars.githubusercontent.com/u/1261928?v=3","gravatar_id":"","url":"https://api.github.com/users/nfl","html_url":"https://github.com/nfl","followers_url":"https://api.github.com/users/nfl/followers","following_url":"https://api.github.com/users/nfl/following{/other_user}","gists_url":"https://api.github.com/users/nfl/gists{/gist_id}","starred_url":"https://api.github.com/users/nfl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nfl/subscriptions","organizations_url":"https://api.github.com/users/nfl/orgs","repos_url":"https://api.github.com/users/nfl/repos","events_url":"https://api.github.com/users/nfl/events{/privacy}","received_events_url":"https://api.github.com/users/nfl/received_events","type":"Organization","site_admin":false},"repo":{"id":37627792,"name":"react-helmet","full_name":"nfl/react-helmet","owner":{"login":"nfl","id":1261928,"avatar_url":"https://avatars.githubusercontent.com/u/1261928?v=3","gravatar_id":"","url":"https://api.github.com/users/nfl","html_url":"https://github.com/nfl","followers_url":"https://api.github.com/users/nfl/followers","following_url":"https://api.github.com/users/nfl/following{/other_user}","gists_url":"https://api.github.com/users/nfl/gists{/gist_id}","starred_url":"https://api.github.com/users/nfl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nfl/subscriptions","organizations_url":"https://api.github.com/users/nfl/orgs","repos_url":"https://api.github.com/users/nfl/repos","events_url":"https://api.github.com/users/nfl/events{/privacy}","received_events_url":"https://api.github.com/users/nfl/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/nfl/react-helmet","description":"Specify the page title, meta & link tags per component in a nested fashion","fork":false,"url":"https://api.github.com/repos/nfl/react-helmet","forks_url":"https://api.github.com/repos/nfl/react-helmet/forks","keys_url":"https://api.github.com/repos/nfl/react-helmet/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nfl/react-helmet/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nfl/react-helmet/teams","hooks_url":"https://api.github.com/repos/nfl/react-helmet/hooks","issue_events_url":"https://api.github.com/repos/nfl/react-helmet/issues/events{/number}","events_url":"https://api.github.com/repos/nfl/react-helmet/events","assignees_url":"https://api.github.com/repos/nfl/react-helmet/assignees{/user}","branches_url":"https://api.github.com/repos/nfl/react-helmet/branches{/branch}","tags_url":"https://api.github.com/repos/nfl/react-helmet/tags","blobs_url":"https://api.github.com/repos/nfl/react-helmet/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nfl/react-helmet/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nfl/react-helmet/git/refs{/sha}","trees_url":"https://api.github.com/repos/nfl/react-helmet/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nfl/react-helmet/statuses/{sha}","languages_url":"https://api.github.com/repos/nfl/react-helmet/languages","stargazers_url":"https://api.github.com/repos/nfl/react-helmet/stargazers","contributors_url":"https://api.github.com/repos/nfl/react-helmet/contributors","subscribers_url":"https://api.github.com/repos/nfl/react-helmet/subscribers","subscription_url":"https://api.github.com/repos/nfl/react-helmet/subscription","commits_url":"https://api.github.com/repos/nfl/react-helmet/commits{/sha}","git_commits_url":"https://api.github.com/repos/nfl/react-helmet/git/commits{/sha}","comments_url":"https://api.github.com/repos/nfl/react-helmet/comments{/number}","issue_comment_url":"https://api.github.com/repos/nfl/react-helmet/issues/comments{/number}","contents_url":"https://api.github.com/repos/nfl/react-helmet/contents/{+path}","compare_url":"https://api.github.com/repos/nfl/react-helmet/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nfl/react-helmet/merges","archive_url":"https://api.github.com/repos/nfl/react-helmet/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nfl/react-helmet/downloads","issues_url":"https://api.github.com/repos/nfl/react-helmet/issues{/number}","pulls_url":"https://api.github.com/repos/nfl/react-helmet/pulls{/number}","milestones_url":"https://api.github.com/repos/nfl/react-helmet/milestones{/number}","notifications_url":"https://api.github.com/repos/nfl/react-helmet/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nfl/react-helmet/labels{/name}","releases_url":"https://api.github.com/repos/nfl/react-helmet/releases{/id}","created_at":"2015-06-18T00:07:34Z","updated_at":"2015-08-31T18:29:48Z","pushed_at":"2015-08-30T06:20:54Z","git_url":"git://github.com/nfl/react-helmet.git","ssh_url":"git@github.com:nfl/react-helmet.git","clone_url":"https://github.com/nfl/react-helmet.git","svn_url":"https://github.com/nfl/react-helmet","homepage":null,"size":340,"stargazers_count":362,"watchers_count":362,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":17,"mirror_url":null,"open_issues_count":6,"forks":17,"open_issues":6,"watchers":362,"default_branch":"master"}},"base":{"label":"nfl:master","ref":"master","sha":"3e5b58303088a397e49f4b26d00926d74f0e780b","user":{"login":"nfl","id":1261928,"avatar_url":"https://avatars.githubusercontent.com/u/1261928?v=3","gravatar_id":"","url":"https://api.github.com/users/nfl","html_url":"https://github.com/nfl","followers_url":"https://api.github.com/users/nfl/followers","following_url":"https://api.github.com/users/nfl/following{/other_user}","gists_url":"https://api.github.com/users/nfl/gists{/gist_id}","starred_url":"https://api.github.com/users/nfl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nfl/subscriptions","organizations_url":"https://api.github.com/users/nfl/orgs","repos_url":"https://api.github.com/users/nfl/repos","events_url":"https://api.github.com/users/nfl/events{/privacy}","received_events_url":"https://api.github.com/users/nfl/received_events","type":"Organization","site_admin":false},"repo":{"id":37627792,"name":"react-helmet","full_name":"nfl/react-helmet","owner":{"login":"nfl","id":1261928,"avatar_url":"https://avatars.githubusercontent.com/u/1261928?v=3","gravatar_id":"","url":"https://api.github.com/users/nfl","html_url":"https://github.com/nfl","followers_url":"https://api.github.com/users/nfl/followers","following_url":"https://api.github.com/users/nfl/following{/other_user}","gists_url":"https://api.github.com/users/nfl/gists{/gist_id}","starred_url":"https://api.github.com/users/nfl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nfl/subscriptions","organizations_url":"https://api.github.com/users/nfl/orgs","repos_url":"https://api.github.com/users/nfl/repos","events_url":"https://api.github.com/users/nfl/events{/privacy}","received_events_url":"https://api.github.com/users/nfl/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/nfl/react-helmet","description":"Specify the page title, meta & link tags per component in a nested fashion","fork":false,"url":"https://api.github.com/repos/nfl/react-helmet","forks_url":"https://api.github.com/repos/nfl/react-helmet/forks","keys_url":"https://api.github.com/repos/nfl/react-helmet/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nfl/react-helmet/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nfl/react-helmet/teams","hooks_url":"https://api.github.com/repos/nfl/react-helmet/hooks","issue_events_url":"https://api.github.com/repos/nfl/react-helmet/issues/events{/number}","events_url":"https://api.github.com/repos/nfl/react-helmet/events","assignees_url":"https://api.github.com/repos/nfl/react-helmet/assignees{/user}","branches_url":"https://api.github.com/repos/nfl/react-helmet/branches{/branch}","tags_url":"https://api.github.com/repos/nfl/react-helmet/tags","blobs_url":"https://api.github.com/repos/nfl/react-helmet/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nfl/react-helmet/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nfl/react-helmet/git/refs{/sha}","trees_url":"https://api.github.com/repos/nfl/react-helmet/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nfl/react-helmet/statuses/{sha}","languages_url":"https://api.github.com/repos/nfl/react-helmet/languages","stargazers_url":"https://api.github.com/repos/nfl/react-helmet/stargazers","contributors_url":"https://api.github.com/repos/nfl/react-helmet/contributors","subscribers_url":"https://api.github.com/repos/nfl/react-helmet/subscribers","subscription_url":"https://api.github.com/repos/nfl/react-helmet/subscription","commits_url":"https://api.github.com/repos/nfl/react-helmet/commits{/sha}","git_commits_url":"https://api.github.com/repos/nfl/react-helmet/git/commits{/sha}","comments_url":"https://api.github.com/repos/nfl/react-helmet/comments{/number}","issue_comment_url":"https://api.github.com/repos/nfl/react-helmet/issues/comments{/number}","contents_url":"https://api.github.com/repos/nfl/react-helmet/contents/{+path}","compare_url":"https://api.github.com/repos/nfl/react-helmet/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nfl/react-helmet/merges","archive_url":"https://api.github.com/repos/nfl/react-helmet/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nfl/react-helmet/downloads","issues_url":"https://api.github.com/repos/nfl/react-helmet/issues{/number}","pulls_url":"https://api.github.com/repos/nfl/react-helmet/pulls{/number}","milestones_url":"https://api.github.com/repos/nfl/react-helmet/milestones{/number}","notifications_url":"https://api.github.com/repos/nfl/react-helmet/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nfl/react-helmet/labels{/name}","releases_url":"https://api.github.com/repos/nfl/react-helmet/releases{/id}","created_at":"2015-06-18T00:07:34Z","updated_at":"2015-08-31T18:29:48Z","pushed_at":"2015-08-30T06:20:54Z","git_url":"git://github.com/nfl/react-helmet.git","ssh_url":"git@github.com:nfl/react-helmet.git","clone_url":"https://github.com/nfl/react-helmet.git","svn_url":"https://github.com/nfl/react-helmet","homepage":null,"size":340,"stargazers_count":362,"watchers_count":362,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":17,"mirror_url":null,"open_issues_count":6,"forks":17,"open_issues":6,"watchers":362,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/nfl/react-helmet/pulls/37"},"html":{"href":"https://github.com/nfl/react-helmet/pull/37"},"issue":{"href":"https://api.github.com/repos/nfl/react-helmet/issues/37"},"comments":{"href":"https://api.github.com/repos/nfl/react-helmet/issues/37/comments"},"review_comments":{"href":"https://api.github.com/repos/nfl/react-helmet/pulls/37/comments"},"review_comment":{"href":"https://api.github.com/repos/nfl/react-helmet/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/nfl/react-helmet/pulls/37/commits"},"statuses":{"href":"https://api.github.com/repos/nfl/react-helmet/statuses/9f2897d98fb399bdfb64903b1921d1637927b097"}}}}