dotnet / razor

Compiler and tooling experience for Razor ASP.NET Core apps in Visual Studio, Visual Studio for Mac, and VS Code.
https://asp.net
MIT License
505 stars 196 forks source link

No intellisense in Blazor Hosted WebAssembly Project: VS 2019 Preview 2.1 #5174

Closed nssidhu closed 3 years ago

nssidhu commented 4 years ago

I am not getting any intellisense for Blazor WebAssembly Hosted Project( Client Side). The problems mainly occur in the Client(Blazor) Project. Server & shared Project i do get intellisense. Feels like i am working in Notepad.

Not sure if this is releated, but i keep on getting this error in Vsiaul studio(On the Top bar)

System.NullReferenceException : Object reference not set to an instance of an object.
   at Microsoft.CodeAnalysis.Razor.MemoryCache`2.<>c.<Compact>b__6_0(KeyValuePair`2 x)
   at System.Linq.EnumerableSorter`2.ComputeKeys(TElement[] elements,Int32 count)
   at System.Linq.EnumerableSorter`1.Sort(TElement[] elements,Int32 count)
   at System.Linq.OrderedEnumerable`1.<GetEnumerator>d__1.MoveNext()
   at System.Linq.Enumerable.ElementAt[TSource](IEnumerable`1 source,Int32 index)
   at Microsoft.CodeAnalysis.Razor.MemoryCache`2.Compact()
   at Microsoft.CodeAnalysis.Razor.MemoryCache`2.Set(TKey key,TValue value)
   at Microsoft.CodeAnalysis.Razor.Serialization.TagHelperDescriptorJsonConverter.ReadJson(JsonReader reader,Type objectType,Object existingValue,JsonSerializer serializer)
   at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.DeserializeConvertable(JsonConverter converter,JsonReader reader,Type objectType,Object existingValue)
   at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.PopulateList(IList list,JsonReader reader,JsonArrayContract contract,JsonProperty containerProperty,String id)
   at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateList(JsonReader reader,Type objectType,JsonContract contract,JsonProperty member,Object existingValue,String id)
   at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateValueInternal(JsonReader reader,Type objectType,JsonContract contract,JsonProperty member,JsonContainerContract containerContract,JsonProperty containerMember,Object existingValue)
   at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize(JsonReader reader,Type objectType,Boolean checkAdditionalContent)
   at Newtonsoft.Json.JsonSerializer.DeserializeInternal(JsonReader reader,Type objectType)
   at Newtonsoft.Json.JsonSerializer.Deserialize[T](JsonReader reader)
   at Microsoft.CodeAnalysis.Razor.Serialization.TagHelperResolutionResultJsonConverter.<>c__DisplayClass4_0.<ReadJson>b__0(String propertyName)
   at Microsoft.CodeAnalysis.Razor.Serialization.JsonReaderExtensions.ReadProperties(JsonReader reader,Action`1 onProperty)
   at Microsoft.CodeAnalysis.Razor.Serialization.TagHelperResolutionResultJsonConverter.ReadJson(JsonReader reader,Type objectType,Object existingValue,JsonSerializer serializer)
   at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.DeserializeConvertable(JsonConverter converter,JsonReader reader,Type objectType,Object existingValue)
   at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize(JsonReader reader,Type objectType,Boolean checkAdditionalContent)
   at Newtonsoft.Json.JsonSerializer.DeserializeInternal(JsonReader reader,Type objectType)
   at Newtonsoft.Json.Linq.JToken.ToObject(Type objectType,JsonSerializer jsonSerializer)
   at Newtonsoft.Json.Linq.JToken.ToObject[T](JsonSerializer jsonSerializer)
   at StreamJsonRpc.JsonMessageFormatter.JsonRpcResult.GetResult[T]()
   at async StreamJsonRpc.JsonRpc.InvokeCoreAsync[TResult](<Unknown Parameters>)
   at async Microsoft.CodeAnalysis.Remote.RemoteEndPoint.InvokeAsync[T](<Unknown Parameters>)
TanayParikh commented 4 years ago

Thanks for reporting this! This should be resolved by https://github.com/dotnet/aspnetcore-tooling/pull/2449 / https://github.com/dotnet/aspnetcore/issues/25358 and will be available in 16.8 preview 3.