Browser Link Visual Studio 2013 not working

2019-02-16 03:55发布

问题:

I am new to VS 2013 and recently got introduced to a feature called Browser Link. I think it's an awesome feature provided by microsoft.

I am not able to get the connections. Following steps I did

  • Created a new Empty MVC project
  • Created a controller Home and Action Index
  • Created a view Index.cshtml.
  • Solution was in debug mode.
  • Ran the solution.

Following is the web.config settings for the project

<?xml version="1.0" encoding="utf-8"?>
<!--
  For more information on how to configure your ASP.NET application,     please visit
  http://go.microsoft.com/fwlink/?LinkId=301880
  -->
<configuration>
  <appSettings>
    <add key="webpages:Version" value="3.0.0.0" />
    <add key="webpages:Enabled" value="false" />
    <add key="ClientValidationEnabled" value="true" />
    <add key="UnobtrusiveJavaScriptEnabled" value="true" />
  </appSettings>
  <system.web>
    <compilation debug="true" targetFramework="4.5.1" />
    <httpRuntime targetFramework="4.5.1" />
  </system.web>
</configuration>

I have gone through the process Microsoft Explained on it's site http://go.microsoft.com/fwlink/?LinkId=313770.

回答1:

To register the Page Inspector's Runtime add the following line to your web.config.

<system.web>
    <compilation debug="true" targetFramework="4.5.1">
      <assemblies>
         <add assembly="Microsoft.VisualStudio.Web.PageInspector.Loader,Version=1.0.0.0, Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a"/>