-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Using Nancy 2 with Razor? #2839
Comments
I believe it is the same as Nancy1 as far as Razor is concerned. I would look at my issue here that others have experienced with Razor before going down that road though: #2731 |
Been doing so (Razor/2.0.0-ClintEastwood).... been fine so far that I recollect. I have 1-2 things in production (internal-only systems) that have been fine. |
I've been uzing Razor with 1.x series but have no idea how to do it with 2.x :/ Because i can't find propoper documentation for 2.x. |
@dealproc there is an issue when the application starts if there are multiple concurrent requests at the same time it can cause a deadlock situation because it caches an assembly that appears to be invalid. The issue is reproducible but I only run into customers complaining about it every 1-2 months on my end. Most know to recycle the application pool again. @bonesoul what issue are you running into? |
I referenced Nancy.ViewEngines.Razor. When i navigate to my webserver; cshtml files are not checked even;
|
I'm trying to get Razor working with Nancy & dotnet core. Note that I'm using in-process nancy in an existing network server code not a new aspnet core website project.
|
@bonesoul I have encountered this issue before. Basically it isn't recognizing the .cshtml extension. I'm trying to recall what it was but I think it had something to do with the System.Web.Razor not being set to Copy Local and the same for Nancy.ViewEngines.Razor. I'm trying to look through my past issues for my project and finding where I documented what this was. |
before nancy 2 & dotnet core update i was using this;
changed it to
but i can't find a BuildProviders folder in new 2.0.0-clienteastwood nancy.viewengines.razor package. maybe related to this https://github.com/NancyFx/Nancy/blob/master/src/Nancy.ViewEngines.Razor/targets/Nancy.ViewEngines.Razor.targets |
I've added the package for Nancy.ViewEngines.Razor.BuildProviders-clienteastwood but still no luck. https://github.com/NancyFx/Nancy/tree/master/src/Nancy.ViewEngines.Razor.BuildProviders |
I was able to get a Razor ViewEngine working in my .net core 2.2 project. If this is helpful to anyone please feel free to use it. Also, if anyone sees anything that I'm doing wrong I'd love to hear from you. https://gist.github.com/teedty1/a505b2a4fb2c48658d127d5d4682628a |
Any news about this? |
I'm trying to get Nancy2 clinteastwood with Razor but couldn't find any guides for so? Any directions?
The text was updated successfully, but these errors were encountered: