0

one juvenile question , i am having a asp.net intranet application which is using jquery, instead of ref jquery to every page, i decided it to put it on the master page inside the script manager scriptReference tag. note not all pages of my application requires jquery, so is it a wise thing to do, or it will affect the performance, any ideas

2 Answers 2

1

It's not a bad idea. It won't affect performance greatly because the JQuery code should be cached by the client. It means you know it's always there and you don't have to think about it when you're adding new pages.

Sign up to request clarification or add additional context in comments.

Comments

1

As long as the URL of the library remains consistent, your users' browsers should cache it the first time it is loaded. Any performance hits from having it included would then be minimal at best.

If possible, a further improvement might be to simply reference one of the many CDNs which host jQuery. This would essentially guarantee that your users would have a cached copy from one website or another.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.