View Full Version : Difference between onDocumentReady() and onReady()
18 Jun 2012, 3:38 AM
Ext provides us two methods onDocumentReady() and onReady(). I did not get any basic difference them.
18 Jun 2012, 9:11 AM
The difference is .. there is less typing using onReady() ... it is just shorthand alias.
6 Feb 2014, 6:17 PM
Thanks Scott :)..
6 Feb 2014, 7:18 PM
As I understand it onDocumentReady is the ExtJS wrapper for DOMContentLoaded, whereas onReady also waits for the framework to be fully prepped and all classes to finish loading.
You'd very rarely need onDocumentReady. Either use onReady or a launch method if you're MVCing.
6 Feb 2014, 11:14 PM
onDocumentReady: Adds a listener to be notified when the document is ready (before onload and before images are loaded).
onReady: Adds a function to be called when the DOM is ready, and all required classes have been loaded.
and other points as mentioned by Skirtle
Powered by vBulletin® Version 4.1.5 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.