Hi @tanimakumari-5311,
JavaScript can be used in asp.net mvc.
If you go for Asp.NET Web forms, there is no need to have a detailed understanding of HTML, CSS or JavaScript as it abstracts all these details and provides automatic plumbing. However, if you’re using ASP.NET MVC, you will need a clear understanding of how HTML, CSS and JavaScript work.
Below is an example using Razor syntax combined with a simple demo of javaScript.
First create a Controller, and then add a view, the code of the View part is as follows:
Result:
When you click "Click to show time!", the current time will be displayed below.
For more usage syntax, please refer to the example.
Introduction to ASP.NET Web Programming Using the Razor Syntax (C#)
You can also use some js frameworks, such as angular ,Vue , ember.
If the answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
Best Regards,
ChaoDeng