如何在Razor中使用逐字标识符? [英] How can a verbatim identifier be used in Razor?
本文介绍了如何在Razor中使用逐字标识符?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在努力实现这一目标,但由于@在Razor中使用,我似乎无法将其用作类型。
I'm trying to accomplish this, but since @ is used in Razor, I can't seem to use it as a type.
@model IEnumerable<@event>
我试过:
I've tried:
@model IEnumerable<@@event>
和
and
@using ev = Namespace.To.@event
@model IEnumerable<ev>
没有成功。
without success.
推荐答案
它似乎正常工作;但智能感知不起作用;和断点无法设置。
It appears to just work; however IntelliSense does not work; and breakpoints cannot be set.
这篇关于如何在Razor中使用逐字标识符?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文