Threaded View
-
17 May 2012 10:09 AM #1
Delegate Ext.Object.chain to Object.create
Delegate Ext.Object.chain to Object.create
This is a performance improvement suggestion.
Ext.Object.chain could be delegated (on supported platforms) to Object.create. This would improve performance.
Object.create
Ext.Object.chain
Try this test. You will see that Object.create is at least 50% faster.
EDIT
Also, see this similar delegation Ext.Object.getKeys --> Object.keys
*** EDIT 5/18/12Code:var obj = { key1: 'xxx', key2: 'yyy', key3: 'zzz', key4: 'www', key5: 'aaa' } console.time('chain'); for (var i=0; i<10000; i++) { Ext.Object.chain(obj); } console.timeEnd('chain'); console.time('create'); for (var i=0; i<10000; i++) { Object.create(obj); } console.timeEnd('create');
See how the Compose library checks if Object.create is available.Last edited by LesJ; 18 May 2012 at 5:49 AM. Reason: Add Compose link
Success! Looks like we've fixed this one. According to our records the fix was applied for
EXTJSIV-8087
in
4.2.0.265.


Reply With Quote