[wp-trac] [WordPress Trac] #55491: Replace `unload` event handlers from core

WordPress Trac noreply at wordpress.org
Sat Oct 7 07:45:49 UTC 2023


#55491: Replace `unload` event handlers from core
----------------------------+--------------------------------------
 Reporter:  shawfactor      |       Owner:  westonruter
     Type:  defect (bug)    |      Status:  accepted
 Priority:  normal          |   Milestone:  6.4
Component:  Administration  |     Version:
 Severity:  normal          |  Resolution:
 Keywords:  has-patch       |     Focuses:  javascript, performance
----------------------------+--------------------------------------

Comment (by shawfactor):

 I’m not sure you are right that it’s disabled for all authenticated
 requests. Is it nocache_headers() that preventing it? AFAICT that’s only
 called on the back end, heartbeat is used by alot of plugins on the front?
 Maybe I’ve missed in the code

 Secondly regardless of the answer that is be default, many people override
 the headers

 Finally chrome are on the path to deprecate the unload event anyway:

 https://developer.chrome.com/blog/deprecating-unload/

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/55491#comment:41>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list