我知道关于生产网站的问题已经有一段时间了。但是,我想知道在开发过程中是否可以采取任何措施来加快网站的初始加载时间。我一直在计时,加载初始主页最多需要 50 秒。后续加载仅需 1 - 3 秒。此外,当我“中断”执行时,它不会在代码中的任何位置停止,而只会说“未找到源代码”。
输出窗口列出了很多:
'iisexpress.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\0a486d18\8cf9a7c5\App_Web_scrollablecontent.ascx.fdc5856b.1gwjfghw.dll', Symbols loaded.
'iisexpress.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\0a486d18\8cf9a7c5\App_Web_newarticles.ascx.44e66049.4ezrpblb.dll', Symbols loaded.
'iisexpress.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\0a486d18\8cf9a7c5\App_Web_rightcolumnmediumrectangleadvert.ascx.57649735.kymbya94.dll', Symbols loaded.
'iisexpress.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\0a486d18\8cf9a7c5\App_Web_main.master.cdcab7d2.lei5axii.dll', Symbols loaded.
'iisexpress.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\0a486d18\8cf9a7c5\App_Web_articleheadline.ascx.c8a8415c.klhhkoqx.dll', Symbols loaded.
'iisexpress.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\0a486d18\8cf9a7c5\App_Web_articleheadlines.ascx.c8a8415c.ikuqn1xd.dll', Symbols loaded.
'iisexpress.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\0a486d18\8cf9a7c5\App_Web_panel.ascx.fdc5856b.a0mhhnzv.dll', Symbols loaded.
'iisexpress.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\0a486d18\8cf9a7c5\App_Web_articlelistingitempanel.ascx.2acfc5c3.nqj5yies.dll', Symbols loaded.
'iisexpress.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\0a486d18\8cf9a7c5\App_Web_otherheadlinespanel.ascx.205896d5.cg_7tycu.dll', Symbols loaded.
'iisexpress.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\root\0a486d18\8cf9a7c5\App_Web_articleheadlinesandotherheadlines.ascx.1d347881.zttdxgh7.dll', Symbols loaded.
此外,输出窗口以每秒 2 到 3 行的速度写入每一行(即每个组件)。该网站使用大量用户控件来使其更有条理。
有什么办法可以加快开发的初始页面加载速度?这确实浪费了开发人员的大量时间,不得不一直等待初始页面加载。我一直在尝试使用 Cassini 和 IIS Express,但两者的加载时间似乎相似。