CSS
-Tricks
treehouse :
what would you like to learn today?
Web Design
Web Development
iOS Development
Show search box
Search
Search in:
All
Articles
Forums
Snippets
Videos
✕
Home
Forums
Snippets
Gallery
Videos
Almanac
Demos
Lodge
Navigation 'n' Search
Forums
Illustration by Nick Sirotich
Forums
»
JavaScript Jungle
Place different jquery codes into a single js file?
kelvinseasons
Permalink to comment
#
September 2009
I'm very new to javascript and jquery and i was wondering if i can have multiple javascript effects (JQuery style) into a single
.js file?
E.g: Menu fade in out effect, lightbox effect, accordion effect all into a handy main.js file?
chriscoyier
Permalink to comment
#
September 2009
You can, and it's generally encouraged. Keeps things neatly together and saves HTTP Requests.
kelvinseasons
Permalink to comment
#
September 2009
Thanks that answer my question.
Add a Comment
.js file?
E.g: Menu fade in out effect, lightbox effect, accordion effect all into a handy main.js file?