How to make razor view engine to use c# 6.0

后端 未结 4 1204
盖世英雄少女心
盖世英雄少女心 2020-12-09 14:57

Currently my razor view engine throws and error saying \"Please use language version 6 or higher\". That may just be resharper giving me a pointer. But how do i make razor u

4条回答
  •  [愿得一人]
    2020-12-09 15:08

    I believe this is due to a bug in the templates for web.config when the project is upgraded to a newer version of the .net framework.

    I was able to fix this by going in to web.config, finding the system.codedom node, and changing the content to look like this:

    
      
      
    
    

提交回复
热议问题