1.

Which of the following computation is correct to calculate the time taken for page load once the page is received from the server?(a) responseEnd-loadEventEnd(b) loadEventEnd-responseEnd(c) loadEventEnd/responseEnd(d) responseEnd/loadEventEndI have been asked this question in an interview for internship.The query is from Invocation of the Performance Object topic in portion Invocation and Performance Navigation of JavaScript

Answer»

Correct answer is (b) loadEventEnd-responseEnd

For explanation I would say: The legacy PerformanceTiming.loadEventEnd read-only property RETURNS an unsigned LONG representing the MOMENT, in milliseconds since the UNIX epoch, when the load event handler terminated, that is when the load event is completed. The time TAKEN for PAGE load once the page is received from the server: loadEventEnd-responseEnd.



Discussion

No Comment Found

Related InterviewSolutions