Live data from Hacker News

Offer HN: I'll answer your javascript questions

news.ycombinator.com

1–10 of 45 posts

Re: Offer HN: I'll answer your javascript questions

#8

I'm a desktop application developer still finding my feet on the web. Should I bother learning "pure" JavaScript or should I just learn a library like JQuery?

You need to learn javascript the language whether or not you use jQuery. You do not, however, need to learn the DOM API if you decide to use jQuery (which I recommend)

Re: Offer HN: I'll answer your javascript questions

#9

I'm a desktop application developer still finding my feet on the web. Should I bother learning "pure" JavaScript or should I just learn a library like JQuery?

If you're a desktop guy, and MS based, learn some silverlight, it's very nice and also a MS-win7 phone.

If you're not, Javascript + JQuery is the way to learn for the client side stuff, you also need a server side language (python, ruby, etc).

Re: Offer HN: I'll answer your javascript questions

#10

I'm a desktop application developer still finding my feet on the web. Should I bother learning "pure" JavaScript or should I just learn a library like JQuery?

So there's 2 questions in there.

1) Should I learn the language? 2) Should I bother learning to use a DOM library like jQuery.

So the answer to both is actually yes. For someone coming to js for the first time, its very important that you at least learn an intermediate amount about the language before you worry about a browser library like jQuery.

You should get your hands on a copy of Javascript the Good Parts by Douglas Crockford. Its a short book, and easily the best written about javascript. The key thing is that the book addresses only the language. It tells you very simply what and what not to do. Learning these basics will help you get up to speed tremendously.

In regards to jQuery, its important to know that the language and the browser are two completely separate things. The language is basically implemented the same in most modern browsers with a few minor exceptions, 90% of which involve older versions of IE. The thing that people always get confused about is that the things DOM libraries wrap around are the various browser DOM APIs that are made accessible via js.

So, get the book. Learn the core tenets of the language. Then use a library to pave over all the rough bits when writing code that's meant to run in different browsers. In this day and age, the less you have to write "low-level" code to run across multiple browsers the happier you'll be. The exception here is if you're writing a web app that has to be very tiny and still function everywhere. A good example would be a widget that 3rd party sites can plug into their pages. You can never rely on another party having jQuery or whatever library you're using, and its cost prohibitive to load an entire 20k library to support your widget.

Post reply on HN