I am precompiling my razor views in my VS publish profile by setting the following properties:
- Precompile options: deselect "Allow precompile site to be updatable", deselect "Emit debug information"
- Merge options: select "Merge all outputs to a single assembly", give name "AppCode", check "Treat as library component (remove the AppCode.compiled file).
In order to test whether my application was actually reading from the compiled views, I renamed one of my cshtml files, and tested locally. All good, the view still loaded fine indicating that the compiled view was being called.
However, when I deployed all the binaries to the server and did the same test by renaming a cshtml file, the browser responsed with server 500 error.
What am I missing please?
question from:
https://stackoverflow.com/questions/66045888/why-is-my-deployed-application-still-reading-the-cshtml-view-instead-of-the-prec 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…