5

I've got an ASP.NET web application, and I'm attempting to reduce HTTP calls to the server, so I'd like to not load things like MicrosoftAjaxWebForms.debug.js and MicrosoftAjax.debug.js.

Script manager is used to form all of my external javascript files into one, and I'm concerned that this is causing other non-related libraries to be loaded.

2 Answers 2

6

To get rid of the debug versions of the scripts you have to disable debug mode in web.config. Find the element called <compilation debug="true"> under /configuration/system.web and change it to <compilation debug="false">.

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

1 Comment

This helped (at least temporarily) resolve a nasty bug on a website with heavy traffic, thanks for posting.
3

It is indeed the ScriptManager that is pulling these in. You might be able to reduce the number of scripts it adds by turning off the different features on it, eg. PageMethods.
Look for the properties that starts with Enable...

Of course, it will probably be easier to just create a small method that does the same as the ScriptManager, all it does is add some <script> tags to the document..

1 Comment

They have all been set to false, but the libraries are still loading.

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.