Suppose I have a view called Login.cshtml
, which I need to load these:
<link href="~/css/particle.css" rel="stylesheet" />
<script src="~/js/particle-js/particles.min.js"></script>
<script src="~/js/particle-js/app.js"></script>
In my application I have also _Layout.cshtml
which contains the basic script to load for each, page. How can I load the script and css above in the when the user access to Login.cshtml
view, as happen in _Layout.cshtml
?
What I learned is the existence of @section
, but I don't if is the best practive to do this, someone could suggest me how to do it properly?
Thanks in advance.