Skip to content

Instantly share code, notes, and snippets.

View IanYates's full-sized avatar

Ian Yates IanYates

View GitHub Profile
namespace Serilog.Exceptions
{
using System;
using System.Collections.Generic;
using System.Linq;
public class AggregateExceptionDestructurer : ExceptionDestructurer
{
public override Type[] TargetTypes
{
@IanYates
IanYates / DelayedRenderExtensions.cs
Created November 3, 2015 02:02 — forked from zaus/DelayedRenderExtensions.cs
RenderSections in PartialViews -- delayed rendering of any HTML content. See SO answer: http://stackoverflow.com/a/18790222/1037948
public static class HtmlRenderExtensions {
/// <summary>
/// Delegate script/resource/etc injection until the end of the page
/// <para>@via http://stackoverflow.com/a/14127332/1037948 and http://jadnb.wordpress.com/2011/02/16/rendering-scripts-from-partial-views-at-the-end-in-mvc/ </para>
/// </summary>
private class DelayedInjectionBlock : IDisposable {
/// <summary>
/// Unique internal storage key
/// </summary>