[NavigationTiming] onload event can't get the 'performance.getEntriesByType("navigation")[0]'

Hello,

         I am a developer in China.my name is Zhou Xianfeng.

         I have read the document in https://www.w3.org/TR/
navigation-timing-2/ .But when I test the example3 mentioned in the
document, it can’t work.

         So ,I check the “performance.getEntriesByType(‘navigation’)”. It
is strange that the length of the array returned is 0.But when I write it
in the developer tools,I can get the right result.

         Can you tell me how I can get the right result of
“performance.getEntriesByType(‘navigation’)”.



         Environment:

                   Crome  57.0.2987.133




                                   Zhou Xianfeng




                                   Sincerely yours

Received on Friday, 7 April 2017 09:27:41 UTC