相关疑难解决方法(0)

在 .net mvc 中从 Bootstrap 3.7 更新到 5.0.2 产生错误 System.NullReferenceException

我卸载了 .net MVC 应用程序附带的基本引导程序模板,并从 NuGetPackage Manager 安装了引导程序 5.0.2。现在我在运行时遇到这个问题(构建成功发生):

System.NullReferenceException
  HResult=0x80004003
  Message=Object reference not set to an instance of an object.
  Source=WebGrease
  StackTrace:
   at Microsoft.Ajax.Utilities.JSParser.ParseObjectLiteralProperty(Boolean isBindingPattern)
   at Microsoft.Ajax.Utilities.JSParser.ParseObjectLiteral(Boolean isBindingPattern)
   at Microsoft.Ajax.Utilities.JSParser.ParseLeftHandSideExpression(Boolean isMinus)
   at Microsoft.Ajax.Utilities.JSParser.ParseUnaryExpression(Boolean& isLeftHandSideExpr, Boolean isMinus)
   at Microsoft.Ajax.Utilities.JSParser.ParseExpressionList(JSToken terminator)
   at Microsoft.Ajax.Utilities.JSParser.ParseMemberExpression(AstNode expression, List`1 newContexts)
   at Microsoft.Ajax.Utilities.JSParser.ParseLeftHandSideExpression(Boolean isMinus)
   at Microsoft.Ajax.Utilities.JSParser.ParseUnaryExpression(Boolean& isLeftHandSideExpr, Boolean isMinus)
   at Microsoft.Ajax.Utilities.JSParser.ParseExpressionStatement(Boolean fSourceElement)
   at Microsoft.Ajax.Utilities.JSParser.ParseStatement(Boolean fSourceElement, Boolean skipImportantComment)
   at Microsoft.Ajax.Utilities.JSParser.ParseBlock()
   at Microsoft.Ajax.Utilities.JSParser.ParseArrowFunction(AstNode parameters)
   at Microsoft.Ajax.Utilities.JSParser.ParseLeftHandSideExpression(Boolean isMinus)
   at Microsoft.Ajax.Utilities.JSParser.ParseUnaryExpression(Boolean& isLeftHandSideExpr, Boolean isMinus)
   at Microsoft.Ajax.Utilities.JSParser.ParseExpressionList(JSToken terminator)
   at Microsoft.Ajax.Utilities.JSParser.ParseMemberExpression(AstNode expression, List`1 …
Run Code Online (Sandbox Code Playgroud)

.net c# asp.net-mvc bootstrap-5

2
推荐指数
1
解决办法
819
查看次数

标签 统计

.net ×1

asp.net-mvc ×1

bootstrap-5 ×1

c# ×1