[dojo-contributors] Optimized/Unoptimized Build Flag?

Brad Neuberg paperairplane at gmail.com
Fri Jun 15 14:59:32 EDT 2007


On 6/15/07, dojo-contributors-request at dojotoolkit.org <
dojo-contributors-request at dojotoolkit.org> wrote:
>
> Send dojo-contributors mailing list submissions to
>         dojo-contributors at dojotoolkit.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
>         http://dojotoolkit.org/mailman/listinfo/dojo-contributors
> or, via email, send a message with subject or body 'help' to
>         dojo-contributors-request at dojotoolkit.org
>
> You can reach the person managing the list at
>         dojo-contributors-owner at dojotoolkit.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of dojo-contributors digest..."
>
> I'm not up on the offline stuff yet, but here are some
> questions/thoughts. In general, I don't think it would be good for you
> to hardcode in a list of things to load, if that is possible. But
> again, I might not understand the problem yet.



I don't hard code the list, that's the point ;) A user adds their stuff to
the offline list:

dojox.off.files.cache("myfile.html");

But, for Dojo to run, there is alot of other stuff if you are a
non-optimized build. This is what
I add internally. I found a way to differentiate optimized and non-optimized
builds.


1) After dojo loads, you can check the dojo._loadedUrls array would
> tell you what files have been loaded. You might also want to intercept
> dojo.require/platformRequire/requireIf/requreAfterIf calls after
> loading in case the application loads new things during the course of
> operation. Does that help?


I already to this actually. The issue is that any build could be using
requires. What I needed was to pull in the loader/bootstrap system if you
are a non-optimized build, which I can now detect by looking for a script
tag that is the _bootstrap.js file.


2) Would it help if we had a gears manifest file? I don't know gears
> yet or how it works with Dojo offline, so this might be the wrong
> question to ask. However, if it would help, perhaps we can see about
> generating one automatically on an svn commit, then during a build,
> the manifest would be updated with the build output?


I don't like the Gears manifest system, since I can't autogenerate it from
the JavaScript. Plus its a bit heavy. What I have is working, using the
non-managed part of Google Gears. Plus, the manifest file could be pulling
in lots of stuff the dev doesn't need.


James
>
>
> ------------------------------
>
> _______________________________________________
> dojo-contributors mailing list
> dojo-contributors at dojotoolkit.org
> http://dojotoolkit.org/mailman/listinfo/dojo-contributors
>
>
> End of dojo-contributors Digest, Vol 39, Issue 23
> *************************************************
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.dojotoolkit.org/pipermail/dojo-contributors/attachments/20070615/301f6f46/attachment.htm 


More information about the dojo-contributors mailing list