To use Blazor you need to have VS2019 preview edition or enable preview features on VS2019 by checking
Tools -> Options -> Environment -> Preview Features -> Use previews of the .NET Core SDK
or on the older versions of VS2019
Tools -> Options -> Projects and Solutions -> .NET Core -> Use previews of the .NET Core SDK
checkbox, then reload the solution and build.