Massive ASP.NET AJAX performance increase with minor effort
Posted: 9/15/2009 2:05:09 PM
By: Comfortably Anonymous
Times Read: 1,817
0 Dislikes: 0
Topic: Programming: Web Applications

Incredible what a speed boost you can get with your ASP.NET AJAX apps by simply adding a few optional parameters. Shockingly faster in a lot of situations!

In your ScriptManager declaration, if you add the following parameters, you should see a very nice performance improvement:

  • EnablePartialRendering="true" (Alows just the parts of the page that have changed to be transmitted across the wire.)
  • LoadScriptsBeforeUI="false" (Postpones quite a few of the script downloads until after the main page content is finished downloading by adding the script references to the end of the tag.)
  • ScriptMode="Release" (Causes AJAX to emit really tight production-ready code. Only drawback to this is when debugging an AJAX issue, you'll need to flip this back to get debug info.)

< asp:ScriptManager ID="ScriptManager1" runat="server" EnablePartialRendering="true" LoadScriptsBeforeUI="false" ScriptMode="Release" />

Rating: (You must be logged in to vote)