Servicestack.net Mini Profiler in razor view

前端 未结 1 1233
花落未央
花落未央 2021-01-13 14:46

Is it possible to use the mini profiler in service stack with the razor views? It looks like the documentation only shows the profiler when using the json html report view.

相关标签:
1条回答
  • 2021-01-13 15:44

    Yes you can include it using the same MVC include but include it .AsRaw() so it doesn't get HTML encoded, e.g:

    @ServiceStack.MiniProfiler.Profiler.RenderIncludes().AsRaw()
    

    Example taken from this RazorRockstars template.

    0 讨论(0)
提交回复
热议问题