Trying to learn jquery

1886
8
07-16-2014 05:18 AM
TimWitt2
MVP Alum

Hey everybody,

I would like to learn some jquery, so I will be able to develop apps for mobile devices.

I know ESRI has a short section on how to implement it with their javascript api. Since it is rather short, does anybody have some pointers where I can explore it a bit more in detail?

Any help would be appreciated!

Tim

8 Replies
RobertScheitlin__GISP
MVP Emeritus

Tim,

   I like this site http://www.jqueryrain.com/

As far as mobile the jQuery Mobile forum is very active jQuery Forum

TimWitt2
MVP Alum

Thanks Robert, those are very useful!

0 Kudos
FilipKrál
Occasional Contributor III

Hi Tim,

The key idea really is described in the sample you have probably discovered too: Using jQuery | ArcGIS API for JavaScript

If you want more, check out this example or esri.github: Esri/jquery-mobile-map-js · GitHub

Go through some of the other repositories there, you can learn a lot from it.

I have been using ArcGIS API for JavaScript with jQuery too and it makes many things so much easier.

Filip.

DavidHansen3
New Contributor II

Code Academy has an entire track for jQuery, which is free. The courses on Code Academy are usually a pretty good place to pick up skills and are pretty straight forward and helpful since you write code while learning the lessons.

jQuery | Codecademy

JeffPace
MVP Alum

I will be in the minority on this, but.

Learning jquery is a great tool to have in your pocket.  When I first started with the javascript API, knowing our systems and development group uses jquery, I started to learn and try to force all things ESRI over to jquery.

I spent a few months awhile ago stripping all the jQuery out of my code.  I found that I can natively do everything I want, usually better, with DOJO. Plus the library is already loaded and I know it works with the js api because it is tested with it.

So preaching aside, if you have to use jquery then absolutely do it.  If you are trying to learn a framework just for working with the javascript api, you will be much better served, both in ease of use and in gained understanding of the workings of the api itself, by learning dojo.

DavidHansen3
New Contributor II

Jeff,

I agree with you 100%. Solid advice. Any new people reading this chain should definitely head his words. You will see a lot of negative talk about DOJO on the general web, but inside of an Esri environment, it just makes sense to go ahead and use it. Newer people have a little trouble wrapping their head around AMD, but it is worth the time to really get to understand it. Also, when using AMD, use a build system. A build system will help your deployment immensely. If you are just extending a template and just need to manipulate the DOM go ahead use jQuery, but the merits of DOJO really come apparent for enterprise level apps. I personally use jQuery all the time when doing general web work, but it is a beast of awesome when it comes to robust GIS apps and it is already there thanks to Esri.

TimWitt2
MVP Alum

Jeff,

thanks for the great advice. I know my way around dojo, but as you said I got a little scared by people talking bad about it and thought I need to take up jquery. I know it sounds silly!

Since I haven't used dojo much in the mobile form, and even ESRI used jquery in some of their mobile samples, I thought I needed to pick up on jquery myself.

Tim

0 Kudos
JeffPace
MVP Alum

Knowledge of jquery is never a bad thing, but dont let anyone tell you you have to use it just because.