#12993 closed defect (wontfix)
call to dojo.ready with dojo.parser buried in dojo*parser definition in build
Reported by: | rott | Owned by: | James Burke |
---|---|---|---|
Priority: | high | Milestone: | tbd |
Component: | BuildTools | Version: | 1.6.1 |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
SVN rev: 25049 Ubuntu Linux 10.10 Sun JDK 1.6 Rhino
Please see attached build profile with name "minimal.js", which only pulls in dijit.form.Button and prefixes dijit.
Command:
./build.sh profile=uploader action=clean,release stripConsole=all layerOptimize=shrinksafe optimize=shrinksafe releaseDir=../../../ cssOptimize=comments releaseName=dojo_optimized copyTests=false version=1.7.0
In minimal.js.uncompressed.js, the following block of code is buried in the definition for dojo*parser:
Register the parser callback. It should be the first callback after the a11y test. if(dojo.config.parseOnLoad){
dojo.ready(100, dojo.parser, "parse");
}
This means simply placing djconfig="parseOnLoad: true" in my <script> tag reference to dojo.js won't trigger the parse. I would have to explicitly require dojo/parser, which does register the event, but well after the browser has triggered the onload. Thus I have to not only explicitly require dojo/parser, I also have to call it. Please see attached index.html.
Attachments (3)
Change History (10)
Changed 11 years ago by
Attachment: | minimal.profile.js added |
---|
comment:1 Changed 11 years ago by
Please make an attempt to reproduce this, as there are additional problems. Using the index.html as is will call the parser, but there are errors such as "Could not load 'dijit.form.Button'" despite that module clearly being defined in the minimal.js build output.
comment:2 Changed 11 years ago by
Correction: profile=uploader should be profile=minimal in the command line.
comment:3 Changed 11 years ago by
Ahhhh... so sorry for the churn on this. I just tested against source. Same problem. In fact, I don't even see parser.js getting downloaded in the network tab in the Chrome dev tools.
Please change to base since this is now not really a builder problem.
comment:4 Changed 11 years ago by
Cancelling this one. I see now that in 1.7 you must explicitly require dojo.parser.
Please cancel.
comment:5 Changed 11 years ago by
Resolution: | → wontfix |
---|---|
Status: | new → closed |
comment:6 Changed 11 years ago by
Just want to clarify, this was closed as "wontfix" but it's more "invalid" really, since in reality dojo.parser was NEVER automatically required for parseOnLoad... See documentation ticket I entered, #12997. (I actually entered that based on feedback by rott on IRC; I hadn't noticed this ticket.)
comment:7 Changed 11 years ago by
it was automatically required by _Templated, and many examples/testcases did not require it... so there are lot's cases where customers have taken these examples and used them...even if technically it was safer to do the require.
profile