tailieunhanh - JQuery: Novice to Ninja- P3

JQuery: Novice to Ninja- P3:No matter what kind of ninja you are—a cooking ninja, a corporate lawyer ninja, or an actual ninja ninja—virtuosity lies in first mastering the basic tools of the trade. Once conquered, it’s then up to the full-fledged ninja to apply that knowledge in creative and inventive ways. | Falling in Love with jQuery 7 What s the downside There barely is a downside The main arguments against using any JavaScript library have always been speed and size some say that using a library adds too much download bloat to pages while others claim that libraries perform poorly compared with leaner custom code. Though these arguments are worth considering their relevance is quickly fading. First as far as size is concerned jQuery is lightweight. The core jQuery library has always had a fairly small footprint about 19KB for the basics less than your average JPG image. Any extras your project needs such as plugins or components from the jQuery UI library can be added in a modular fashion so you can easily count your bandwidth calories. Speed like size is becoming a decreasing concern as computer hardware specifications rise and browsers JavaScript engines grow faster and faster. Of course this is far from implying that jQuery is slow the jQuery team seem to be obsessed with speed Every new release is faster than the last so any benefit you might derive from rolling your own JavaScript is shrinking every day. When it comes to competing JavaScript libraries and there are more than a handful out there jQuery is the best at doing what jQuery does manipulating the DOM adding effects and making Ajax requests. Still many of the libraries out there are of excellent quality and excel in other areas such as complex class-based programming. It s always worth looking at the alternatives but if the reasons we ve outlined appeal to you jQuery is probably the way to go. But enough talk time for jQuery to put its money where its mouth is Downloading and Including jQuery Before you can fall in love with jQuery or at least judge it for yourself you need to obtain the latest version of the code and add it to your web pages. There are a few ways to do this each with a couple of options available. Whatever you choose you ll need to include jQuery in your HTML page just as you would .

crossorigin="anonymous">
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.