- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
当我为 ASP.Net Core 1.1 应用程序启用 BrowserLink 时,我在浏览器中收到以下错误,我认为是因为 BrowserLink 不起作用。
Browser Link: Exception thrown when trying to invoke Browser Link extension callback "microsoft.visualstudio.web.browserlink.sourcemappingextensionfactory.getCssMappingData":
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NullReferenceException: Object reference not set to an instance of an object.
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.VsWebUrlUtil.EnsureAbsoluteUrl(IVsHierarchy hierarchy, Uri& path)
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.VsWebUrlUtil.GetSimpleVsWebUrlFromUrl(IVsHierarchy hierarchy, Uri url, ILocationContainer& container)
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.VsWebUrlUtil.GetVsWebUrlFromUrl(IVsHierarchy hierarchy, Uri url)
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.LazyLocationContainer.LazyLocationContainerFromUrl.CreateActualLocationContainer()
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.LazyLocationContainer.GetPhysicalPath(Uri& physicalPath)
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.DocumentLocation.Microsoft.VisualStudio.Web.Extensions.Common.Helpers.IDocumentLocation.GetPhysicalPath(Uri& physicalPath)
at Microsoft.VisualStudio.Web.BrowserLink.SourceMappingExtension.getCssMappingData(String cssUrl, String[] selectors)
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at Microsoft.VisualStudio.Web.BrowserLink.ClientMessaging.DispatchMessage(BrowserLinkConnection connection, MessageArgs obj)
Browser Link: Exception thrown when trying to invoke Browser Link extension callback "microsoft.visualstudio.web.browserlink.autosyncextensionfactory.trackCssDocuments":
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NullReferenceException: Object reference not set to an instance of an object.
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.VsWebUrlUtil.EnsureAbsoluteUrl(IVsHierarchy hierarchy, Uri& path)
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.VsWebUrlUtil.GetSimpleVsWebUrlFromUrl(IVsHierarchy hierarchy, Uri url, ILocationContainer& container)
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.VsWebUrlUtil.GetVsWebUrlFromUrl(IVsHierarchy hierarchy, Uri url)
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.LazyLocationContainer.LazyLocationContainerFromUrl.CreateActualLocationContainer()
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.LazyLocationContainer.GetPhysicalPath(Uri& physicalPath)
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.DocumentLocation.Microsoft.VisualStudio.Web.Extensions.Common.Helpers.IDocumentLocation.GetPhysicalPath(Uri& physicalPath)
at Microsoft.VisualStudio.Web.Extensions.Common.Helpers.DocumentLocation.Microsoft.VisualStudio.Web.Extensions.Common.Helpers.IDocumentLocation.get_PhysicalFileExists()
at Microsoft.VisualStudio.Web.BrowserLink.AutoSyncExtension.trackCssDocuments(String[] trackHrefs, String[] untrackHrefs)
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at Microsoft.VisualStudio.Web.BrowserLink.ClientMessaging.DispatchMessage(BrowserLinkConnection connection, MessageArgs obj)
Browser Link: Failed to invoke return value callback:
TypeError: Cannot read property 'files' of null
<ItemGroup>
<PackageReference Include="AutoMapper" Version="5.2.0" />
<PackageReference Include="AutoMapper.Extensions.Microsoft.DependencyInjection" Version="1.2.0" />
<PackageReference Include="BundlerMinifier.Core" Version="2.4.337" />
<PackageReference Include="IdentityModel" Version="2.5.1" />
<PackageReference Include="Microsoft.AspNetCore.Authentication.Cookies" Version="1.1.1" />
<PackageReference Include="Microsoft.AspNetCore.Authentication.OpenIdConnect" Version="1.1.1" />
<PackageReference Include="Microsoft.AspNetCore.Diagnostics" Version="1.1.1" />
<PackageReference Include="Microsoft.AspNetCore" Version="1.1.1" />
<PackageReference Include="Microsoft.AspNetCore.Mvc" Version="1.1.2" />
<PackageReference Include="Microsoft.AspNetCore.StaticFiles" Version="1.1.1" />
<PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="1.1.1" PrivateAssets="All" />
<PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="1.1.1" />
<PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer.Design" Version="1.1.1" PrivateAssets="All" />
<PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="1.1.0" PrivateAssets="All" />
<PackageReference Include="Microsoft.Extensions.Configuration.EnvironmentVariables" Version="1.1.1" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="1.1.1" />
<PackageReference Include="Microsoft.Extensions.Logging" Version="1.1.1" />
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="1.1.1" />
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="1.1.1" />
<PackageReference Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="1.1.1" />
<PackageReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Design" Version="1.1.0" PrivateAssets="All" />
<PackageReference Include="Microsoft.VisualStudio.Web.BrowserLink" Version="1.1.0" />
<PackageReference Include="Serilog.Extensions.Logging.File" Version="1.0.0" />
</ItemGroup>
<ItemGroup>
<DotNetCliToolReference Include="Microsoft.EntityFrameworkCore.Tools.DotNet" Version="1.0.0" />
<DotNetCliToolReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Tools" Version="1.0.0" />
</ItemGroup>
<Target Name="PrepublishScript" BeforeTargets="PrepareForPublish">
<Exec Command="bower install" />
<Exec Command="dotnet bundle" />
</Target>
app.UseBrowserLink();
.
Browser Link: Failed to invoke return value callback:
TypeError: Cannot read property 'files' of null
最佳答案
在使用 VS2017 在 .NET Core 中搜索浏览器链接的修复程序时,我首先登陆了这个线程。
我所缺少的只是
app.UseBrowserLink();
Configure
方法。
关于asp.net-core - BrowserLink 不适用于 Visual Studio 2017 RTM 上的 ASP.NET Core,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42694973/
我对“browserLink”有一些误解请看下面 没关系.. 但是 当我在输入标签上添加 type="text" 时,我会得到 Uncaught Error: Syntax err
在 VS 2013 下运行基于 Razor 的 Web 项目时,使用 IIS,我在 browserLink 中看到以下错误: Uncaught Error: Syntax error, unrecog
将.Net Core 2.2升级到.Net Core 3.0我的浏览器链接变得不起作用,有人知道如何排除故障。 执行编辑 cshtml 并刷新浏览器,它没有反射(reflect)更改。 最佳答案 解决
自从在 Visual Studio 2017 中升级到 ASP.NET Core 2.1 后,BrowserLink 不再有效。如果我使用基本的“ASP.NET Core Web 应用程序”模板,选择
我一直在使用 Visual Studio 2013 并且喜欢浏览器链接功能。但是,有时它会在 chrome 或 ie 的开发人员控制台中给我 404。 (其他浏览器没试过): 难道我做错了什么?它没有
如何让 BrowserLink 在 MVC6 中工作 - 使用 RC1 Release 1。使用 Visual Studio 2015 Update 1。 浏览器永远不会出现在浏览器链接仪表板中。没有
我无法在 ASP.NET Core 2.0 中同步 CSS。 这就是我所做的: 使用 MS 模板创建全新的应用 启动生成的模板(存在 app.UseBrowserLink()) 尝试通过将背景颜色设置
当我为 ASP.Net Core 1.1 应用程序启用 BrowserLink 时,我在浏览器中收到以下错误,我认为是因为 BrowserLink 不起作用。 Browser Link: Except
我是一名优秀的程序员,十分优秀!