I am trying to use static html partial viewd from the asp.net mvc views folder in angularjs, but it doesn't seem to work. Is it possible at all or I must create a new folder for these? Ideally I would like to keep all views in the same folder.
Asked
Active
Viewed 50 times
1 Answers
1
You can get access to the static files in Views folder by changing web.config setting to this.
<add name="BlockViewHandler" path="*.cshtml" verb="*" preCondition="integratedMode" type="System.Web.HttpNotFoundHandler" />
You need to change path="*"
to path="*.cshtml"
, this will allow all other file types to be allowed directly.
I answered this question in bit more detail here, https://stackoverflow.com/a/24789089/3421839