Beispiel #1
0
        public static Strainer Create(Context context)
        {
            Strainer strainer = new Strainer(context);

            foreach (var keyValue in Filters)
            {
                strainer.Extend(keyValue.Value);
            }
            return(strainer);
        }
Beispiel #2
0
 /// <summary>
 /// Pass a module with filter methods which should be available
 ///  to all liquid views. Good for registering the standard library
 /// </summary>
 /// <param name="filter"></param>
 public static void RegisterFilter(Type filter)
 {
     Strainer.GlobalFilter(filter);
 }