我正在尝试在我的 asp.net MVC 6 项目中使用 NHaml 作为 ViewEngine。我通过 Mono 在我的 OSX 系统上运行这个项目。NHaml 文档https://code.google.com/p/nhaml/wiki/Configuration说要使用 .xml 配置文件。但看起来 MVC 6 不再支持 xml 配置
'IConfigurationSourceRoot' does not contain a definition for 'AddXmlFile'
and no extension method 'AddXmlFile' accepting a first argument
of type 'IConfigurationSourceRoot' could be found
(are you missing a using directive or an assembly reference?)
如何将此配置转换为 json 语法,或者只是简单地在代码中正确配置此配置?由于我对 .net 的经验非常有限,这个问题可能令人困惑。