We Talked jQuery With The Experts – This Is What Went Down.

Sarah Hawk

This morning (for us Antipodeans, anyway) we ran the 7th in our Talk With The Experts series and it saw us talking jQuery with Craig Sharkie and Earle Castledine, authors of jQuery: Novice to Ninja eds 1 & 2. We discussed everything from semicolons (always use them) to testing. People shared some great resources, especially for beginners, but the highlight for me was roping Craig into taking part in our next session, which will be about responsive design.

On the subject of upcoming sessions, I have some exciting things in the works (responsive and HTML5 just to name a couple), but I’m always on the look out for more. I’d love to hear what it is that you’re interested in.  What topics would you like to see us offering? If anyone out there is an ‘expert’ in a subject and would be interested in taking part in a session, please get in touch. And lastly, I’ve been trialling different chat products but still haven’t managed to find the perfect one. If anyone knows of a product (primary requirements are guest access and downloadable transcripts) then please let me know.

If you missed this morning’s session and would like to know what went down, here is a transcript.

HAWK HAWK
Morning everyone. I’m HAWK, Community Manager at SitePoint. Welcome to talk jQuery with the Experts. Introduce yourselves – where are you? What do you do?
HAWK HAWK
Earle and Sharkie are in the room, so if anyone has any pressing questions, feel free to jump in at any time.
nicksh nicksh
can anybody tell me wtich is the best jquery content slider?
Kestrel Kestrel
@nicksh there isn’t a best one but i do love slidedeck
Expert_S… Expert_Sharkie
@nicksh which sliders have you looked at?
Wojciech… WojciechFornal
seen some slidedeck demos and I must admin it’s quite impressive tool
Wojciech… WojciechFornal
^admit
Kestrel Kestrel
@nicksh do you need a free content slider?
Jason Jason
I am working on an application using a lot of jquery and css. What is the best file structure for storing all of my scripts and stylesheets?
semicolo… semicolon
what are the twitter handles of the experts?
Expert_S… Expert_Sharkie
I always opt for a directory for each in the server root
HAWK HAWK
Agreed @Kestrel
Jason Jason
i mean more within the scripts folder
Jason Jason
because i have different kinds of scripts, like managers and models
Jason Jason
i started to look into using more of a MVC framework, but i dont know if i can easily retrofit my current code
Expert_S… Expert_Sharkie
@Jason Since your code and css will be concatenated and minified when it’s published it’s hard to say
Expert_E… Expert_Earle

View / Edit paste

@semicolon - I'm @mrspeaker (because I'm Mr Speaker), and Craig is @twalve
Eip56 has entered the room
Kestrel Kestrel
@jason def make sure you keep the version numbers of the scripts in your filename system you will always run up against a versioning bug eventually and it will be much harder to maintain older pages without it
stevenga… stevengardner
Intro: Kinda getting to grips with javascript with codeacademy but have a bit of limited experience with jquery. I have build a mobile version of our site with jquery mobile.
semicolo… semicolon
thanks
Sega Sega
Is there something up on code academy with jQuery?
Robertb has entered the room
Sega Sega
I’ve been using CodeAvengers
littletechguy has entered the room
Sega Sega
but that’s JS only I think
Miro has entered the room
Jason Jason
@Kestrel as in a comment at the top of the file with the version number?
Miro Miro
hi all
HAWK HAWK
Hey @Miro
stevenga… stevengardner
There may well be but I’m kinda going through javascript in order they set it up. I think they have or are planning jquery courses
nicksh nicksh
sorry was away
nixony has entered the room
Miro Miro
:)
rotex has left the room
Sega Sega
@stevengardner take a look at codeavengers
@stevengardner it’s awesome!
Kestrel Kestrel
no i mean put the version number of the script in the filename itself. Such as jquery.awesome-buttons.1.0.1.js
stevenga… stevengardner
just pasted it in my search box
semicolo… semicolon
codeavengers is awesome
Eip56 Eip56
@stevengardner
are you trying ot learn
Expert_E… Expert_Earle
@Jason – are you having some particular problem with your organisation, or is just a general query?
Eip56 Eip56
to*
Min has entered the room
stevenga… stevengardner
@eip56
@eip56 yeah
Anto has left the room
jsteele has entered the room
Kestrel Kestrel
@jason a lot of scripts you find on the internet won’t do this and i recommend you do this for your own scripts as well
Anne has entered the room
jocasio has entered the room
stevenga… stevengardner
I’m loving it. I need to beef up my front end skills as my contract comes to an end at the end of the year
Min Min
Hi everyone, good day. I would like to know how to learn Jquery in short period of time.
rishi89 rishi89
@Kestrel is there any “build script” to automate such things ?
Eip56 Eip56
@stevengardner Have you checked out the @sitepoint j@uery novice to ninja book. great book to get you started with jQuery. Fundamentally it will help you understand JavaScript over all as well.
Sega Sega
@semicolon sure is! Been on the course for a bit and learned lots. I got the Sitepoint jQuery books and JavaScript books and there are pretty sweet too! Sitepoint books are really well written.
Miro has left the room
Eip56 Eip56
@min check my previous comment
Expert_S… Expert_Sharkie
@Min Well we know a good book …
Min Min
Thanks.
I will do – SitePoint jquery.
stevenga… stevengardner
@eip56 yeah I have it at home and at work. Its very good and I just today picked it up to look up .animate
semicolo… semicolon
@sega yes i have JS: novice to ninja and i loved it
Jason Jason
more just a general query. Here is a bit of a background. i recently came into the problem of IE only allowing 31 css files to be included. After i resolved that i realized that having an include for every css and js file in head the decorator is probably not the best way to go. So i started to look into frameworks to take care of including the only what is needed for that page. that brought me to require.js and then that brought be to backbone.js. Now i think i have to rethink how i am writing my modules and including them
let me know if that doesnt make any sence
HAWK HAWK
Jason Jason
*sense
Sega Sega
@min you won’t regret it! Honestly, these books are very well written! I have had no trouble going through them
Eip56 Eip56
Yea I had a more general understanding. Got the book and now I would consider myself a lot better after reading it. I can pretty much tackle any project.
itmitică itmitică
jQuery on server-side?
Nate has left the room
Kestrel Kestrel
@rishi89 not that i’m aware of. I do it manually but then I also template my pages so includes aren’t repeated too frequently to make it an issue
Expert_E… Expert_Earle
@Min – easiest way is to have a project – even if it’s just something you made up (Like, a todo app or something). And work through each problem as you hit it. I hate trying to learn a new tech without a practical goal.
kraz has entered the room
alamo has entered the room
jjbloodhound has left the room
Anne has left the room
kraz kraz
asd
mattbtay has entered the room
kraz kraz
joz
anekola has left the room
Sega Sega
@itmitică server side? how would that work?
JoseBran… JoseBranez
I recommend novice to ninja too, great book!
itmitică itmitică
I’m asking that :)
HAWK HAWK
Morning to everyone that has just joined us. I’m HAWK, Community Manager at SitePoint. Welcome to talk jQuery with the Experts. Jump in with questions at any point.
Expert_S… Expert_Sharkie
@jason With that many files you might need to rethink more than file structure. You’re also impacting page performance
nicksh nicksh
@hawK
damn i pressed enter
HAWK HAWK
haha @nicksh
Mike has entered the room
Min Min
Many thanks. i will set new basic project.
nicksh nicksh
@hAWK can i find you on facebook?
Eip56 Eip56
@Min generally my way of learning new languages: Learn basic syntax complete simple tasks > get some kind of reference (cough Sitepoints novice to ninja) >get comfortable with the code > learn how to optimize your code ie utilizing OOP
Kestrel Kestrel
@jason @expert_Sharkie
Expert_E… Expert_Earle
@jason – to me that sounds a bit crazy, separate CSS files (kind of misses the “cascading” part of CSS ;)) but if it works for your project then just run them through a concatenator before you send it to the browser. You certainly don’t want to take the hit of 50 http requests per page!
semicolo… semicolon
i have a general question, semicolons, after that huge argument all over the web a few weeks back, what’s your take on them? should you implicitly add them in your code or not?
Expert_S… Expert_Sharkie
And it seems if you write an @ in your message it will autocomplete names for you. Just tab through the options once you’ve typed a little
stevenga… stevengardner
I had a discussion with out back end developers today about loading jQuery through the google CDN. They were of the opinion that locally hosting it would be better. I tried to explain some of the benefits but they struggled to be converted.
HAWK HAWK
Do you mean me personally or SitePoint @nicksh ?
alamo has left the room
Min Min
Thanks @Eip56. will do. Best one.
stevenga… stevengardner
anyone else had trouble trying to convince people to let google host jquery
victorc victorc
What are folks using for testing, tdd, bdd? Recommended resources?
nicksh nicksh
@hAWK personally
Kestrel Kestrel
@jason @expert_Sharkie I def agree you need to get that include count down as it will be making the page take an age to load on slower connections!
Expert_S… Expert_Sharkie
@semicolon Always add semicolons
nicksh nicksh
@stevengardner so serving via Google CDN is better? damn my entire life was a lie
Expert_E… Expert_Earle
@semicolon Always add semicolons.
stevenga… stevengardner
well I’m not sure anymore!
Eip56 Eip56
@semicolon always add them man. Don’t get in lazy habits. Its one less thing you will have to worry about when debugging a script
Expert_S… Expert_Sharkie
@semicolon You need them to help you maintain the flow when you’re reading
pepeng has entered the room
semicolo… semicolon
@expert_Sharkie i’m glad you agree! :)
mattbtay has left the room
Jason Jason
@Expert_Earle ill look into the concatenators. can you specify what gets added on a page by page basis or is it just for all files at once? and would they work with js file too?
nicksh nicksh
Im hosting jQuery because i have one js file where i put all the js to lower requests
Sega Sega
How do you debug your scripts, what do you use?
semicolo… semicolon
@expert_Earle i’m glad you agree too! :)
Expert_E… Expert_Earle
ASI was added to help out the newbies, and then abused by the hipsters ;)
Min has left the room
Expert_S… Expert_Sharkie
@nicksh CDN’s are great, but browsers aren’t quite so great at caching
Kestrel Kestrel
@nicksh you should def consider using the minimised version of jquery on a CDN (googles is good)
Expert_E… Expert_Earle
@stevengardner – what were their counter-arguments to not using the CDN?
pepeng pepeng
anybody advise me where to start learning jquery?
semicolo… semicolon
@expert_earle ohh don’t tell that to @fat (twitter) ;)
nicksh nicksh
ok i’ll use google’s CDN, is it gzip-enabled?
Eip56 Eip56
@expert_Sharkie The argument would be that you needed something version specific
littletechguy has left the room
Nick has left the room
stevenga… stevengardner
@expert_Sharkie that we have super fast dedicated local servers. Viewing our site behind our firewall delays the load time of google cdn jQuery so skews their perception to it.
WojciechFornal has left the room
stevenga… stevengardner
I am trying to show them the errors of their ways.
Eip56 Eip56
@expert_Sharkie CDN is great. But will new versions break your script? Clients have a fit and if you are not staying up-to-date it is something that could bite you in the butt. So just host the jQuery locally and you would never theoretically have to worry about version changes…. not so progressive though.
Mike Mike
@pepeng TutsPlus published a 30 (or 31?) part video series you can watch free. Originally intended as a one-day-course.http://tutsplus.com/lesson/hello-jquery/
stevenga… stevengardner
@eip56 you can specify what version you use from the cdn
Expert_S… Expert_Sharkie
@eip56 I’d still opt for versioned files from the CDN
Zomi has left the room
Kestrel Kestrel
@stevengardner still the CDN should be the same speed once cached and the hit rate will be much higher as lots of sites use the same CDN
Eip56 Eip56
@Expert_Sharkie Yes you can
pepeng pepeng
wow tnx mike
jsteele has left the room
nixony has left the room
rishi89 rishi89
@HAWK any place where the jquery source is explained ?
Eip56 Eip56
@expert_Sharkie But I believe they only host a few versions back from the current. SOmeone correct me on that if I am wrong.
HAWK HAWK
@rishi89 The jQuery source? I’m not sure I understand your question.
semicolo… semicolon
@mike great link! thx
Expert_S… Expert_Sharkie
@Eip56 They host old versions, but only show newer ones
strzlee has entered the room
stevenga… stevengardner
@kestrel yeah thats my argument. they’re comeback is plugins may stop working if host changes
Kestrel Kestrel
@Eip56 i’m pretty sure google have quite a lot of versions of jquery hosted not since version 1 because they started hosting it later than that but maybe from 1.3 upwards?
Eip56 Eip56
So this is the current but insteat of 1.7 you would define say 1.3 https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js
rishi89 rishi89
@HAWK sort of an annotated / plain english of the jquery code .. ?
Eip56 Eip56
komiska has left the room
HAWK HAWK
@rishi89 I’m not aware of any resources, but it’s not really my area. Maybe someone else knows of something?
stevenga… stevengardner
Have any of you used another framework?
Eip56 Eip56
I have to run all but I enjoyed the chat. Hopefully I catch the next one. Hope to see some of you on twitter @Eip56 :-)
Sega Sega
@stevengardner prototype.js
Expert_S… Expert_Sharkie
@stevengardner I started with Prototype and YUI
stevenga… stevengardner
So what do you use most common
Sega Sega
@stevengardner jQuery
Expert_E… Expert_Earle
@rishi89 – I don’t know of anyone explaining it piece by piece – but the source is very clean and pretty easy to read, and if you don’t understand an architectural choice then they are relatively friendly on the forums
HAWK HAWK
Thanks @Eip56 havea great day
Kestrel Kestrel
@eip56 you can also specify 1 in google CDN and it will update to the latest version thats in 1 so for example 1.5, 1.6, 1.7.1 but not version 2 when it comes out
stevenga… stevengardner
The market seems to be saturated with jquery
semicolo… semicolon
i used to use prototype, but i think it’s pretty much dead now
stevenga… stevengardner
Is that a good thing or bad.
Mike Mike
Started with YUI2. Definitely more verbose, but I felt there was some benefit to that. Make errors more slowly or something. jQuery’s abstractions sometimes worry me that slow things are being done behind my code.
rishi89 rishi89
@Expert_Earle thanks. I’ll give it another shot. Kinda scared of John Resig’s rep.. :)
Eip56 has left the room
stevenga… stevengardner
Many people just skip javascript. Myself included until recently
Kestrel Kestrel
@stevengardner I think jquery was really the first framework to get its act together and keep consistency with updates
Expert_E… Expert_Earle
@stevengardner – I’ve been going down the “more plain old javascript” route too. I think as browsers incorporate more useful DOM manipulation stuff (like querySelectorAll) then it plugs some of the holes that the libraries were made to circumvent
semicolo… semicolon
@stevengardner i think many of us did, but Douglas Crockford changed many people’s minds
stevenga… stevengardner
will search Douglas Crockford
semicolo… semicolon
@stevengardner including mine
Mike Mike
“JavaScript: The Good Parts” is his famous book
semicolo… semicolon
yes
rishi89 rishi89
@ALL – guys, since we are all eager learners here.. I think I should share a perfect gem of a book I found – “Apprentice Patterns” -http://ofps.oreilly.com/titles/9780596518387/index.html
semicolo… semicolon
for a quick presentation about his book try this presentation
Expert_E… Expert_Earle
Make sure you watch every video in the Crockford on Javascript series: https://www.youtube.com/playlist?list=PL7664379246A246CB – START TO FINISH! You end up with a great understaning of why we are where we are
Sega Sega
cool.
pepeng has left the room
semicolo… semicolon
to me his best good parts presentation
stevenga… stevengardner
brilliant thanks. I think I have watched a couple in the past when i think about it.
semicolo… semicolon
i’ve seen all of them
Expert_S… Expert_Sharkie
I’m looking forward to seeing what Crock does now that he’s left Yahoo!
victorc victorc
I’m looking into QUnit and Jasmine for testing, tdd, and bdd w/ JQuery. Any others worth checking out?
semicolo… semicolon
@expert_sharkie me too!
hopefully paypal lets him do presentations as often as yahoo did
Expert_E… Expert_Earle
And gone to paypal! Weird guy ;)
tsokaloshi has entered the room
stevenga… stevengardner
The latest jQuery plugin I used was super labels https://github.com/remybach/jQuery.superLabels very cool for our login form
Expert_S… Expert_Sharkie
@victorc That’s a great place to start
nicksh nicksh
@haWK does sitepoint have other chats?
HAWK HAWK
Hi @tsokaloshi. Welcome. Feel free to jump in with questions at any time.
achrae has entered the room
semicolo… semicolon
anyone watching fluent conf online?
rlburnside has entered the room
tsokalos… tsokaloshi
Howdy
HAWK HAWK
@nicksh Yup, I run one every fortnight. Next up is Responsive Design, followed by HTML5 next month. I advertise them via Twitter @sitepointdotcom, on our Facebook page facebook.com/sitepoint and on the forums.
nicksh nicksh
@tsokaloshi Howdy ho!
Sega Sega
yep Responsive!
Jason has left the room
stevenga… stevengardner
My aim is that I can start building my own tailored plugins instead of including large over complicated plugins. Don’t know if I’l get their any time soon.
nicksh nicksh
@hAWK that’s what i wanted! Responsive design is awesome
stevenga… stevengardner
Will defo be attending the next few chats
Sega Sega
I am doing a responsive layout pretty soon. :)
Expert_E… Expert_Earle
@victorc – I’ve only used QUnit. It does what I need, so I haven’t looked further.
michael has left the room
nicksh nicksh
I have done 2-3 responsive layouts
achrae has left the room
Expert_S… Expert_Sharkie
@stevengardner Plugins are a great route. It’ll lead you to writing more JavaScript
nicksh nicksh
i’m trying to make a responsive page builder http://dev.responsivizr.com/
jquertylearner has entered the room
Sega Sega
look at 320
semicolo… semicolon
bootstrap!
HAWK HAWK
Cool, well make sure you come to that one. We need people that have experience to share them.
Expert_E… Expert_Earle
Woah, I didn’t realise Fluent was “happening now” thanks for the heads up @semicolon
stevenga… stevengardner
do you guys set up variables then use them instead of using dom selectors all the time. I’m trying to work out if its more efficient
Mike Mike
Question: How do people typically organize their JS (multiple modules/functions)? Grouping into a single file to reduce requests and initiating how?
victorc victorc
@Expert_Earle: thanks. Will keep looking for good books and tutorials on them.
Sega Sega
@semicolon what’s bootstrap?
Expert_S… Expert_Sharkie
@nicksh That’s a mighty goal and great URL
nicksh nicksh
@stevengardner of course
Mike Mike
@stevengardner I usually do, yes.
Sega Sega
@Mike for template I have them separate, but for eventual rendering I think they need to be together
itmitică itmitică
@experts: jQuery means to be an equivalent for the simplicity in html and css. is this a javascript failure, and it will be replaced by something easier in the near future?
Expert_E… Expert_Earle
@nicksh – catch name!
stevenga… stevengardner
Ah good! I’m on the right track
nicksh nicksh
@expert_Earle and i got it for free, both hosting and domain :D
Expert_S… Expert_Sharkie
@stevengardner It’s more efficient
Expert_E… Expert_Earle
@nicksh (catchy)
semicolo… semicolon
@sega bootstrap is twitter’s responsive CSS/JS framework
nicksh nicksh
not by default
jquertylearner has left the room
semicolo… semicolon
Mike Mike
@Sega so once combined (whether auto or manual, effect is the same) how do particular pages call, or setup listeners to the code that is relevant to them? Small inline script calling your init() funcs?
tsokalos… tsokaloshi
@stevengardner if you gonna use a selector more than once you should always declare a var
Expert_S… Expert_Sharkie
@itmitică HTML and CSS are both becoming broader, and so more like JavaScript :)
sethjenks has entered the room
stevenga… stevengardner
@tsokaloshi thanks I wasn’t sure how many times i used it before it was more efficient to declare a vairable
Mike Mike
What I mean is a combined script will include functions I don’t need to execute on some pages. What’s the best practice for getting pages to execute the JS they need.
JayD has entered the room
semicolo… semicolon
@expert_Earle no prob! im watching it at work right now :)
Expert_S… Expert_Sharkie
@mike Within reason, once its called on one page of your site it’s their in cache so there’s no need to not call it again. You just need to handle the first loads
adrianleb has entered the room
Expert_E… Expert_Earle
@itmitică I would never accuse CSS of being simple! But really jQuery is fixing the DOM’s problems, not JavaScripts. Everyone knows the DOM is mess ;)
nicksh nicksh
btw somebody tell me if you find background effect on this page annoying http://responsivizr.com/
tsokalos… tsokaloshi
@stevengardner also for some reason your selector changes, you only have to change the variable.
rishi89 has left the room
Mike Mike
When I say “call” I mean execute, rather than just load the script.
Expert_S… Expert_Sharkie
@nicksh if you have to ask … ? :D
semicolo… semicolon
haha
Ulle has entered the room
karinvsoest has entered the room
stevenga… stevengardner
@tsokaloshi thanks
itmitică itmitică
@experts: it’s strange, isn’t it? html5 and css3 step into behavior mine filed, yet js doesn’t keep up with innovation needs
kraz has left the room
sethjenks has left the room
Mike Mike
For example if you had a gallery lightbox and contact form JS combined into one file which gets loaded on both types of pages. How does the contact page avoid executing photo gallery JS, and the gallery page avoid executing the funcs for the contact form?
stevenga… stevengardner
anyone used jQuery mobile. I build a site in it and loved it m.fifedirect.org.uk
jQuery mobile uses HTML5 CSS3
semicolo… semicolon
nice site
Expert_S… Expert_Sharkie
@mike use IDs in your selectors which are page specific
tsokaloshi has left the room
stevenga… stevengardner
@semicolon
thanks
Going to start putting in geolocation and take advantage of local storage
Sega Sega
I have to go people
:)
Expert_S… Expert_Sharkie
I would have thought more people would have had Gravatars, but there are lots of G’s in the Who’s Here list :)
Sega Sega
Thanks for this, I learned something new, and the book jQuery book is awesome for what I need to learn
stevenga… stevengardner
I also built our cookies solution with a lot of jQuery www.fifedirect.org.uk
Expert_S… Expert_Sharkie
@sega Thanks for coming
Expert_E… Expert_Earle
@itmitică – javascript is a programming language… it evolves like a programming language. JS.next has some super cool features. What specifically do you think it’s missing?
HAWK HAWK
@Expert_Sharkie Mine isn’t working
stevenga… stevengardner
@haWK
Kestrel Kestrel
@Expert_Sharkie plenty of service i use support Gravatars but never really felt the urge to set one up
adrianleb has left the room
Expert_S… Expert_Sharkie
@kestrel I love seeing my first edition mascot pop up on sites :)
Sega has left the room
karinvso… karinvsoest
@Expert_Sharkie I use Gravatars, but still end up changing it manually in many places that support it..
Kestrel Kestrel
@Expert_Sharkie something to be very proud of :-)
HAWK HAWK
Not such a fan of the second ed one, huh @Expert_sharkie ?
itmitică itmitică
@experts: the simplicity jQuery has. html and css could have easily be programming languages too.
Ulle has left the room
strzlee has left the room
Expert_S… Expert_Sharkie
@itmitică HTML5 definitely has that feel. There’s a lot of power in the new APIs
Ulle has entered the room
Expert_E… Expert_Earle
@Mike – For larger projects I usually have a “controller” javascript object that determine what to fire on each page and only bind the event handlers that a necessary for that page.
overachieve has entered the room
overachi… overachieve
hello~
Mike Mike
So that controller inspects the DOM (looking for IDs), loads the appropriate JS and calls their init methods?
HAWK HAWK
hey @Overachieve, welcome.
Feel free to jump in with questions at any time.
stevenga… stevengardner
what things in javascript is jQuery not good at?
Ulle_ has entered the room
Expert_S… Expert_Sharkie
@mike Another option is to set the events in a script element in the page and have scripts themselves load externally
Ulle has left the room
karinvsoest has left the room
Ulle_ Ulle_
Here we go, had to change to mac from iphone so i can join the conversation :D
stevenga… stevengardner
@Ulle_ hi
spived spived
hi, we build a page for a newspaper, doing a slideshow of the print edition,http://prueba.agenciareforma.com/webs/elnorte/libre/divcom/edicionimpresa/default.htm?seccion=gente&fecha=20120502
using jquery
Mike Mike
I’ve done that before (<script> element at bottom to call inits)
Expert_S… Expert_Sharkie
@stevengardner Array manipulation? But that’s not what it’s for :)
stevenga… stevengardner
@expert_sharkie cool
Ulle_ Ulle_
@stevengardner hi m8 :) I read your comments about jquery Mobile :)
itmitică itmitică
@experts: html5 makes js easier for a few particualr tasks. what next? with what jQuery may be replaced to make it even easier?
jocasio has left the room
JoseBranez has left the room
Expert_S… Expert_Sharkie
@stevengardner but jQuery isn’t meant to replace JavaScript so you can expect there’ll be gaps
Kestrel Kestrel
jquery is javascript just as wordpress is php
JayD has left the room
Expert_S… Expert_Sharkie
@itmitică You can expect jQuery core to get smaller as HTML5 becomes more widespread
stevenga… stevengardner
@ulle_ yeah I love it. @Expert_Sharkie Yeah I know but I want to know what not to expect from jQuery. Probably not a great question to be honest.
Ulle_ Ulle_
@kestrel Aggreed on that :)
semicolo… semicolon
bootstrap presentation live right now
Ulle_ Ulle_
@stevengardner have you tried zepto.js for mobile solutions?
@stevengardner just to be curious :)
stevenga… stevengardner
@Ulle_ will have a look
Expert_S… Expert_Sharkie
@ulle_ Zepto isn’t just for Mobile :)
semicolo… semicolon
that guy is the one that started the whole semicolon argument on github over the bootstrap JS code
nicksh nicksh
@semicolon thanks
Expert_E… Expert_Earle
@Mike it depends – for common components you might just hava script that targeted specific classes (like, every page load try and bind the lightbox to all .lightbox elements), but for page specific things I tend to have a controller calls “init” on load and then binds the specific things for that page. If I only have one lightbox on the whole site, and it’s not really generic then I’ll bind it in my page controller for that particular page
Ulle_ Ulle_
@expert_Sharkie :) Do know, though thats where I have used it once :)
overachieve has left the room
evanrose has left the room
Robertb has left the room
Ulle_ Ulle_
So far, sadly. Havent yet tried jQuery mobile, but will look into it most definitely
Expert_S… Expert_Sharkie
@Ulle_ I’ve used it to control television UIs.
itmitică itmitică
@experts: it’s true for jQuery to get smaller as CSS3 adds more features. but what next? what could be better than jQuery and not predefined in html5 and css3?
stevenga… stevengardner
@ulle_ yeah its quick and easy to get started. Supports a huge amount of devices and exploits html5 & CSS3
Ulle_ Ulle_
@expert_Sharkie sweet!
Kestrel Kestrel
@expert_Sharkie jquery mobile must be fast if it works on a TV :)
victorc victorc
@stevengardner: nice site. i want to try jquery mobile now.. and maybe move to fife too.
Expert_S… Expert_Sharkie
@itmitică Its not just language changes that are happening. Browser engines are also improving so jQuery is becoming faster
nicksh nicksh
Bootstrap is awesome!
stevenga… stevengardner
@victorc cheers. A responsive version of our full site wouldn’t work great for our customers so jQuery was a good option at the time.
Ulle_ Ulle_
Though for mobile, I have tried to use as little js as possible on my projects which mostly consists of B2B and B2C websites
Expert_S… Expert_Sharkie
@kestrel Sorry … the “it” was Zepto. Mobile is great on Mobile though
Ulle_ Ulle_
or.. as little use of jQuery :)
That would be the correct way to say it :D
Expert_S… Expert_Sharkie
@Ulle_ Using as little JavaScript – and jQuery – is a great approach!
Expert_E… Expert_Earle
@itmitică also, browsers are in more places now – on phones, in hand held consoles, regular consoles, washing machines… I think there will be more niche libraries that cater to specific specialities. It’s hard to have one-size-fits-all – just look a jQuery Mobile ;)
stevenga… stevengardner
Our site is fully js and degrades to simple text and links no style or anything. used for older devices. Most modern smartphones cope well with js CSS HTML.
Expert_E… Expert_Earle
(Just kidding jQuery Mobile, I think you’re good, I do…)
stevenga… stevengardner
I don’t think its the ideal solution but it suits us just now.
Expert_S… Expert_Sharkie
@stevengardner Progressive Enhancement is the way to go!
HAWK HAWK
Hey guys, 5 minutes before I cut our experts free, so if anyone lurking has a question that they’d like to ask, now is the time.
itmitică itmitică
@experts: yeah, i looked at it. it’s defacing every web site and it confuses users whether it’s the new settings UI in their smartphone :)
stevenga… stevengardner
Yeah I’m a huge advocate of progressive enhancement but I work in a large team and this was the way they wanted to go.
Ulle_ Ulle_
Man I came here too l8 :D
@stevengardner what sorta site you were talkin about when @victorc commented “nice site” :)
spived spived
Is there another way to know how a window resize? Instead of $(window).resize, some browsers fire the event many times.
stevenga… stevengardner
m.fifedirect.org.uk
Ulle_ Ulle_
Thanks, will check that out :)
stevenga… stevengardner
I would of liked to try a responsive solution but there was too much political will for a separate solution
Expert_S… Expert_Sharkie
@spived That’s in the book! Check it out :)
Ulle_ Ulle_
Thats sad @stevengardner :(
I know the feeling.
I love responsive, I must say. Almost as much as coffee.
Or the responsive approach, though content first :)
Kestrel Kestrel
@stevengardner always a future version round the corner
Expert_E… Expert_Earle
@spived – you mean it fires multiple times as you drag the window? which browser?
stevenga… stevengardner
The main site is massive and does a tonne of stuff so it would of been a huge task and taken ages. jQuery mobile was a quick solution
Expert_S… Expert_Sharkie
@stevengardner separate solutions is still a response, and your team now know they have options
Kestrel Kestrel
@stevengardner you’ll get to built a responsive version eventually :)
Ulle_ Ulle_
I recommend Stephen Hays presentation on Responsive Design – Work flow :=
:)
datarater has entered the room
paulwilkins has entered the room
HAWK HAWK
You’re an hour late @paulwilkins. We’re just wrapping up! ;)
stevenga… stevengardner
we’re already talking about changing cms so that will be the perfect opportunity. Hopefully I’m still around when its starts.
nicksh nicksh
wish me good luck, i’m installing Android 4.0.4 on SE Xperia X8 :)
stevenga… stevengardner
@nicksh good luck!
itmitică itmitică
bye everyone, have a nice day/night! thanks @experts for insight.
paulwilk… paulwilkins
Yes, that’s a shame – I was looking forward to this too
Expert_E… Expert_Earle
@spived – but I’m not sure… but whenever there are multiple events fired for something (like, a flood of events) then I usually set a flag… initialised to false, then move to true when it fires. THen check the flag in the handler and just return if you’ve already handled it
datarate… datarater
It’s 9pm GMT now isn’t it?
Ulle_ Ulle_
@stevengardner though sometimes seperate mobile solution is more efficient then responsive :)
click has entered the room
Expert_E… Expert_Earle
@spived though i’m not sure that makes sense for the resize event. What’s your use case?
stevenga… stevengardner
Its defiantly a faster loading solution than any css responsive solution.
nicksh nicksh
check out http://nicksh.com , it’s responsive
Ulle_ Ulle_
@stevengardner hmm, I have different solutions for that :)
spived spived
adjusting an iframe
stevenga… stevengardner
@nicksh cool. I’m starting work on my own portfolio site. should be doing it now!
Ulle_ Ulle_
@stevengardner could give you a few links to check out, articles about content loading on responsive, using jQuery of course ;)
HAWK HAWK
Me again… we’re officially ending now, but feel free to hang around as long as you like – I’ll leave the room open all day.
itmitică has left the room
click has left the room
Expert_S… Expert_Sharkie
@spived Earle’s solution is the one I used at Atlassian to control frame resizing
Ulle_ Ulle_
Thanks experts! Nice chat w/ yall!
stevenga… stevengardner
fire them over. I do do a lot of reading on responsive stuff but always looking for something new.
HAWK HAWK
I’m hoping to get logs published – just depends on the constraints of Talkerapp
stevenga… stevengardner
cheers
Ulle_ Ulle_
Though next time, Ill come sooner :D
Expert_S… Expert_Sharkie
Thanks for coming along everyone
Expert_E… Expert_Earle
@spived hmm, I’m not sure there’s a better way, but the good ol’ “setTimeout with a flag” trick would surely work.
Kestrel Kestrel
awesome thanks everyone :)
stevenga… stevengardner
@haWK cheers have a great day!
Expert_E… Expert_Earle
Oh, thanks all!
HAWK HAWK
I’ll publish the time/date for the Responsive session next week. Thanks for your time everyone.
spived spived
oh ok, let me search it, thank you!
semicolo… semicolon
thank you experts
Ulle_ Ulle_
Responsive session, will be there, sweet :)
victorc victorc
thanks for all the great leads. cheers
cspascha… cspaschal
thx
stevenga… stevengardner
@experts cheers
Mike Mike
goodbye & good luck
nicksh nicksh
Good bye everyone, have a good day/night :) here is 1:03AM
Expert_E… Expert_Earle
Good night (and morning) all!
HAWK HAWK
A huge thanks for @Expert_Earle and @Expert_Sharkie for their time.
Ulle_ Ulle_
@stevengardner nice site, by so far :)
semicolo… semicolon
@HAWK thanks
stevenga… stevengardner
@ulle_ cheers!
nicksh nicksh
http://www.facebook.com/shvelo96 if anybody wants to find me
Expert_Sharkie has left the room
stevenga… stevengardner
@stevengardner twitter username cheers!
victorc has left the room
Ulle_ Ulle_
Was about to ask that ;)


Free book: Jump Start HTML5 Basics

Grab a free copy of one our latest ebooks! Packed with hints and tips on HTML5's most powerful new features.

  • Andrés Anguita

    Many thanks! Very useful stuff for dummies like me.