Jump to content

What Are Reasons to Learn Actual JavaScript When I have jQuery?


chaseman

Recommended Posts

To all the JS supporters, this questions is not meant to provoke.

 

I'm genuinely asking myself and trying to think of reasons to learn actual JS when there's jQuery.(?)

 

I'm a web developer and recently I'm spending a lot of time participating in the booming market of template design. Today and yesterday I spent a lot of time learning jQuery and I have to say I grasped it fairly quickly. And I figured quickly that I basically can do anything with it what I always wanted to do, but always lacked the skills to do. I can pep up my websites with jQuery and make them real sleek and dynamic, it is a lot of fun to work with it.

 

I imagined jQuery to be a bit more limited, but I figured the opposite is the case.

 

Now I'm asking myself what would be reasons to learn real JS, maybe you can give me some examples I didn't think of?

 

I would imagine that I would need actual JS for more technical tasks.

 

The next language I wanted to learn was CURL, so I can combine it with my PHP skills.

 

 

 

 

 

 

Link to comment
Share on other sites

I assume you're thinking about using JavaScript to manipulate the DOM and do other UI effects? As long as you and your employers don't mind you hefting around the jQuery suitcase everywhere you go, whatever.

 

If you meant JavaScript in general then I'd be speechless.

 

And cURL isn't a language. The only thing to learn are the various options an invocation can be configured with.

Link to comment
Share on other sites

There isn't any real reason to learn actual JS unless you just don't have access to jquery.  Then I could see the benefit of knowing JS.

 

jQuery is a great framework.. awesome really.  It has become so awesome that nearly everyone is using it nowadays as a JS substitute and in the past when that type of thing happens,.. you have a shiny new cult language.  Much like how PHP started out.. as a simple framework.  A way for someone to code lazily yet just as efficiently.

 

If jQuery doesn't survive the years and stay where it's at in popularity then something else is bound to come along and "replace" JS again.  Your question is essentially the same thing as asking if it's worth it to learn C.  .. and the answer is, it won't hurt you if you do and it'll have it's benefits.  There's really no cons to knowing a language.

Link to comment
Share on other sites

zanus, thank you a lot, your post describes perfectly the perspective I was coming from. As said I imagined jQuery to be much more limited, more like a simple add-on that you'd use for most common effects, but I figured quickly I can do anything with it that I always wanted to be able to do - and that only with a few lines of code (I was pretty amazed). And your analogies are making sense.

 

requenix, I'm not really seeing from which perspective you're coming form. Did you take offense to my post? As said, it wasn't meant to provoke. Sorry about the cURL confusion, I'm only programming since a few month and I was simply fascinated by the thought of programming bots, that's why I wanted to get into it.

Link to comment
Share on other sites

Personally I'd say learn JavaScript. jQuery is obviously written in JavaScript, and knocking how the language works is always beneficial for better code. There's also aspects of JavaScript jQuery doesn't touch; such as strings, dates and numbers. These core objects, even in jQuery, are still accessed and manipulated in the same way. Little things like that, and of course knowing the constructs and abilities of the language, I think make it worthwhile.

Link to comment
Share on other sites

I agree with MrAdam, even if it's just for doing something like this:

 

Array.prototype.inArray = function(value) {
    //
};

Array.prototype.forEach = function(callback) {
    //
};

var a = ['a', 'b', 'c'];
alert(a.inArray('c'));

var d = a.forEach(function(k, v) { return k+v; });

Link to comment
Share on other sites

Yeah, there are a few functions in JS that a debugger just can't do without.. such as

alert() & confirm()

 

and there are a few others I'm sure, but in all sincerity, at this point in time, when jQuery is so dominant, JS is only great for debugging.  I can't see myself entering jQuery commands to check variables in a debugger.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.