Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 604637
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T17:03:35+00:00 2026-05-13T17:03:35+00:00

One of my co-workers is thinking that it is simpler to just include the

  • 0

One of my co-workers is thinking that it is simpler to just include the document.ready() calls (MULTIPLE) for jquery anywhere in an html document, rather than trying to have them all in the head, foot or in an external js file. Can you give me your thoughts about this?

The document.ready stuff is loaded by modules that are included in a main template. I think this is messy. But I need a good argument point.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T17:03:35+00:00Added an answer on May 13, 2026 at 5:03 pm

    There are a number of problems with your coworker’s approach:

    • It’s not DRY. You must repeat the code each time you want to invoke it.
    • No ability to cache the same Javascript; it must be loaded with each new page.
    • If you decide to do it a different way later, N files are now different instead of one.
    • It will not be immediately obvious to a maintainer that this code is repeated across N different files.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

One of my co workers is under the impression that when adding an index
One of my co-workers is building a C# windows app that needs to grab
I have three tables, one is tasks which are tasks that factory workers complete
I have 2 machines running same workers. One machine shoud be primary as it
One of the neat characteristics of UTF-8 is that if you compare two strings
So I'm working on a framework-esque system with one of my co-workers. Our current
While working on some custom validators in WPF, one of my co-workers pointed me
When it comes to documenting the structure of XML files... One of my co-workers
how does one include other .js files in the .js of a Worker. Every
For one subject in college I need to use Windows Azure . Notice that

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.