Quantcast
Channel: Active questions tagged blazor - Stack Overflow
Viewing all articles
Browse latest Browse all 4839

Adding a javascript file to the .Net 8.0 Blazor web assembly project

$
0
0

I created a new .NET 8.0 Blazor application in Visual Studio by following these steps:

  1. Create a new project via the "Blazor Web App" template

  2. Select "Blazor Web Assembly" as the renderer

enter image description here

The new project consists of client and server projects. I created a new JavaScript file in the wwwroot folder of the client project and want to call the JS file in the index.html (like what was in .NET 7.0). However, there is no index.html file in the client project; there is only an App.razor file in the server project.

How can I add the JS file to the client project?

enter image description here


Viewing all articles
Browse latest Browse all 4839

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>