I’m not sure if i shell use cdn or local. Does local means the jquery resources need to be installed on the smartphone, so that an offline app is possible ?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Local, in this case, means that you host the files yourself (as part of your website), rather than relying on a CDN, also it does NOT mean they need to be installed on the device.
Once the libraries are downloaded, the application can be used without a data connection until the cache is cleared. Of course, this depends on your actual application, if it requires a data connection to query things on a server it won’t work, but this has nothing to do with the offline availability of the JS libraries.
Either way, you will need a data connection at first.
The benefit of a CDN hosted library is that it might have been loaded for another website already, so when the users access your website they don’t need to download it again.
However, there are other factors to consider, for example:
For jQueryMobile, however, it is more likely that another website is using it (and the same version) than it is with jQuery, so I would recommend using the CDN version.