Suppose I want to override the function inside the native code provided by Sencha in the ext-all-debug.js file .
The function is defined inside the Ext.util.Renderable class and has the name cacheRefEls .
redefinition should take place inside the index.html of the project in order to simplify its support for future releases.
I have already tried the override solutions proposed in this thread:
Steps to override Sencha ExtJS component functionality (Ext.tree.Panel and Ext.data.TreeStore as two examples)
My index.html is as follows:
<html> ... <script type="text/javascript"> Ext.define('Myapp.view.Renderable', { override: 'Ext.util.Renderable', cacheRefEls: function(el) { console.log("in overider method"); </script> ... </html>
Unfortunately, after accessing localhost: 8080 through Firefox-33 from Firebug-2-Console-log, it is clear that it still uses its own version of the function.
What am I missing here?
source share