Opened 12 years ago
Closed 12 years ago
#8597 closed defect (wontfix)
performance: dojo.js could be faster
Reported by: | Douglas Hays | Owned by: | anonymous |
---|---|---|---|
Priority: | high | Milestone: | tbd |
Component: | Core | Version: | 1.2.3 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
I noticed 2 performance issues wrt the getRootNode method in dojo.js:
1) it starts looking for its script at 0 but its always found at the last script since the scripts are being run as they are encountered, so starting with the last and working backwards would be faster.
2) getRootNode() is called twice, firstly to get the root path and secondly to get the script node reference - it should cache the value since the function does a lot of DOM ops
Note: See
TracTickets for help on using
tickets.
This is for the src version of dojo.js -- in general this file is just used for testing raw source and is not designed to be extremely efficient. The getRootNode() may or may not be called twice depending on if djConfig.baseUrl is defined. I do not feel a great urgency to fix this, so closing it as wontfix.
If you have noticed a measurable decrease in performance, it would be good to know, but otherwise closing as wontfix.