I'm not sure I follow the problem Remi.

If you are suggesting that it is possible to jump into the middle of
the app without loading the surrounding framework including iui.js,
iui.css etc then that would trash the whole app.

If you are suggesting the path to the custom.js file might be obscure
then it can be made as "fully qualified" as iui.js itself - whatever
that is.

If you are suggesting there is wasted bandwidth and unnecessary
downloaded code I can only say that in our case the "execute
javascript element" code is pretty short and is executed on a very
frequent basis.  The app is entirely internal to our site so it is
only accessed by wi-fi at present and bandwidth is the least of our
problems.

Don't forget the end-user is not downloading the entire functional
javascript at the <head> of the application - he is just downloading
the little snippet that parses the fragment, extracts the eventual
javascript for the new page, and executes it.  The page specific js is
downloaded with the page to which it applies and is not transmitted if
it is not needed.

In any case I am just reporting what we actually do in a production
application and so far it has not produced any grief.  If anybody else
finds it useful - good for them.

Skip



On Dec 4, 8:30 am, Remi Grumeau <[email protected]> wrote:
> > Now in the <head> element of the first HTML page of your iUI project
> > add the following line as the last js declaration:
>
> > <script type=\"application/javascript\" src=\"myproject.js\"></script>
>
> Which is actually the whole point … i'd rather say "issue".
> Let's imagine i have a webapp with a products list with bunch of JS, a store 
> locator using Google Maps, … and GA for analytics.
> A visitor which is not using the Map section will download the whole Maps 
> Javascript for nothing.
>
> In this example case, that's not too bad … but for a biggest website / 
> webapp, this could be a real first load timing issue.
> Am i wrong ?
> The only solution then would be to use a non-sliding target _blank link ?
>
> Remi
>
>  smime.p7s
> 2KViewDownload

--

You received this message because you are subscribed to the Google Groups 
"iPhoneWebDev" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/iphonewebdev?hl=en.


Reply via email to