[英]How to auto-generate html template in a .cshtml file in Visual Studio 2022?
While doing an ASP.NET project, I created a blank Details.cshtml
file in Visual Studio 2022. After that, I wanted to auto-generate an html template in the file, like below -在做一个 ASP.NET 项目时,我在 Visual Studio 2022 中创建了一个空白的
Details.cshtml
文件。之后,我想在该文件中自动生成一个 html 模板,如下所示 -
<html xmlns=""http://www.w3.org/1999/xhtml>
<head>
<title></title>
</head>
<body>
</body>
</html>
I thought that typing html
and then pressing Tab would do the trick (as per the 3:30 timestamp in this video ), however it didn't work.我认为输入
html
然后按 Tab 键就可以解决问题(根据该视频中的 3:30 时间戳),但它不起作用。 When I searched on the inte.net, all I got was VS Code related results, not even one result talked about Visual Studio .当我在 inte.net 上搜索时,我得到的所有结果都是与 VS Code相关的结果,甚至没有一个结果谈到Visual Studio 。
Can anybody please help me with this?有人可以帮我吗?
I believe you can do that just with typing single ":" and pressing TAB :)我相信您只需键入一个“:”并按 TAB 键就可以做到这一点 :)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.