Socket
Socket
Sign inDemoInstall

liquidjs

Package Overview
Dependencies
Maintainers
1
Versions
206
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

liquidjs - npm Package Compare versions

Comparing version 7.5.1 to 8.0.0

dist/scope/context.d.ts

17

CHANGELOG.md

@@ -0,1 +1,18 @@

# [8.0.0](https://github.com/harttle/liquidjs/compare/v7.5.1...v8.0.0) (2019-03-10)
### Code Refactoring
* use camelCase for JavaScript APIs ([64e0c87](https://github.com/harttle/liquidjs/commit/64e0c87))
### Features
* promise support for drops, working on [#65](https://github.com/harttle/liquidjs/issues/65) ([4a8088d](https://github.com/harttle/liquidjs/commit/4a8088d))
### BREAKING CHANGES
* Options and method names in JavaScript API are now renamed to cammelCase, for a complete list see #109
## [7.5.1](https://github.com/harttle/liquidjs/compare/v7.5.0...v7.5.1) (2019-03-05)

@@ -2,0 +19,0 @@

2

dist/drop/drop.d.ts
export declare abstract class Drop {
valueOf(): any;
liquidMethodMissing(key: string): string | undefined;
liquidMethodMissing(key: string): Promise<string | undefined> | string | undefined;
}

@@ -22,3 +22,3 @@ import Scope from './scope/scope';

renderFile(file: string, ctx?: object, opts?: LiquidOptions): Promise<string>;
evalValue(str: string, scope: Scope): any;
evalValue(str: string, scope: Scope): Promise<any>;
registerFilter(name: string, filter: FilterImpl): void;

@@ -25,0 +25,0 @@ registerTag(name: string, tag: ITagImplOptions): void;

@@ -1,2 +0,2 @@

!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t=t||self).Liquid=e()}(this,function(){"use strict";var r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)};function i(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var v=function(){return(v=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}).apply(this,arguments)};function c(o,s,u,a){return new(u||(u=Promise))(function(t,e){function n(t){try{i(a.next(t))}catch(t){e(t)}}function r(t){try{i(a.throw(t))}catch(t){e(t)}}function i(e){e.done?t(e.value):new u(function(t){t(e.value)}).then(n,r)}i((a=a.apply(o,s||[])).next())})}function h(n,r){var i,o,s,t,u={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return t={next:e(0),throw:e(1),return:e(2)},"function"==typeof Symbol&&(t[Symbol.iterator]=function(){return this}),t;function e(e){return function(t){return function(e){if(i)throw new TypeError("Generator is already executing.");for(;u;)try{if(i=1,o&&(s=2&e[0]?o.return:e[0]?o.throw||((s=o.return)&&s.call(o),0):o.next)&&!(s=s.call(o,e[1])).done)return s;switch(o=0,s&&(e=[2&e[0],s.value]),e[0]){case 0:case 1:s=e;break;case 4:return u.label++,{value:e[1],done:!1};case 5:u.label++,o=e[1],e=[0];continue;case 7:e=u.ops.pop(),u.trys.pop();continue;default:if(!(s=0<(s=u.trys).length&&s[s.length-1])&&(6===e[0]||2===e[0])){u=0;continue}if(3===e[0]&&(!s||e[1]>s[0]&&e[1]<s[3])){u.label=e[1];break}if(6===e[0]&&u.label<s[1]){u.label=s[1],s=e;break}if(s&&u.label<s[2]){u.label=s[2],u.ops.push(e);break}s[2]&&u.ops.pop(),u.trys.pop();continue}e=r.call(n,u)}catch(t){e=[6,t],o=0}finally{i=s=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}([e,t])}}}var n={};function s(t,e){n[t]||(console.warn(t+" See: https://github.com/harttle/liquidjs/issues/"+e),n[t]=!0)}var e=Object.prototype.toString;function d(t){return"[object String]"===e.call(t)}function o(t){return"function"==typeof t}function a(t){return l(t)?"":o((t=u(t)).to_s)?(s("to_s is deprecated, use toString instead.",109),t.to_s()):String(t)}function u(t){return o(t.to_liquid)?(s("to_liquid is deprecated, use toLiquid instead.",109),u(t.to_liquid())):o(t.toLiquid)?u(t.toLiquid()):t}function l(t){return null==t}function g(t){return"[object Array]"===e.call(t)}function f(t,e){for(var n in t=t||{})if(t.hasOwnProperty(n)&&!1===e(t[n],n,t))break;return t}function p(t){return t[t.length-1]}function m(t){var e=typeof t;return null!==t&&("object"===e||"function"===e)}function y(t,e,n){void 0===n&&(n=1);for(var r=[],i=t;i<e;i+=n)r.push(i);return r}function w(t,e,n){void 0===n&&(n=" ");for(var r=e-(t=String(t)).length;0<r--;)t=n+t;return t}var b=function(){function t(){}return t.prototype.valueOf=function(){},t.prototype.liquidMethodMissing=function(t){},t}(),t=function(r){function t(t,e){var n=r.call(this,t.message)||this;return n.originalError=t,n.token=e,n}return i(t,r),t.prototype.update=function(){var i,o,t,s,e=this.originalError,n=(i=this.token,o=i.input.split("\n"),t=Math.max(i.line-2,1),s=Math.min(i.line+3,o.length),y(t,s+1).map(function(t){var e=t===i.line?">> ":" ",n=w(String(t),String(s).length),r=o[t-1];return""+e+n+"| "+r}).join("\n"));this.message=function(t,e){e.file&&(t+=", file:"+e.file);return t+=", line:"+e.line+", col:"+e.col}(e.message,this.token),this.stack=this.message+"\n"+n+"\n"+this.stack+"\nFrom "+e.stack},t}(Error),T=function(r){function t(t,e){var n=r.call(this,new Error(t),e)||this;return n.name="TokenizationError",r.prototype.update.call(n),n}return i(t,r),t}(t),x=function(r){function t(t,e){var n=r.call(this,t,e)||this;return n.name="ParseError",n.message=t.message,r.prototype.update.call(n),n}return i(t,r),t}(t),k=function(r){function t(t,e){var n=r.call(this,t,e.token)||this;return n.name="RenderError",n.message=t.message,r.prototype.update.call(n),n}return i(t,r),t}(t),E=function(n){function t(t){var e=n.call(this,t)||this;return e.resolvedHTML="",e.name="RenderBreakError",e.message=t+"",e}return i(t,n),t}(Error),q=function(n){function t(t){var e=n.call(this,t)||this;return e.name="AssertionError",e.message=t+"",e}return i(t,n),t}(Error);function S(t,e){if(!t)throw new q(e=e||"expect "+t+" to be true")}var O,R,M={root:["."],cache:!1,extname:"",dynamicPartials:!0,trimTagRight:!1,trimTagLeft:!1,trimOutputRight:!1,trimOutputLeft:!1,greedy:!0,tagDelimiterLeft:"{%",tagDelimiterRight:"%}",outputDelimiterLeft:"{{",outputDelimiterRight:"}}",strictFilters:!1,strictVariables:!1};function L(t){var e;(t=t||{}).hasOwnProperty("root")&&(t.root=g(e=t.root)?e:d(e)?[e]:[]);for(var n=0,r=Object.keys(t);n<r.length;n++){var i=r[n];if(-1<i.indexOf("_")){var o=i.replace(/_([a-z])/g,function(t,e){return e.toUpperCase()});s(i+" is deprecated, use "+o+" instead.",109),t[o]=t[i]}}return t}function F(t){return v({},M,t)}(R=O||(O={}))[R.OUTPUT=0]="OUTPUT",R[R.STORE=1]="STORE";var D=O,P=function(){function t(t,e){void 0===t&&(t={}),this.blocks={},this.groups={},this.blockMode=D.OUTPUT,this.opts=F(e),this.contexts=[t||{}]}return t.prototype.getAll=function(){return this.contexts.reduce(function(t,e){return v(t,e)},{})},t.prototype.get=function(t){var r=this,e=this.propertyAccessSeq(t),n=this.findContextFor(e[0])||p(this.contexts);return e.reduce(function(t,e){var n=r.readProperty(t,e);if(l(n)&&r.opts.strictVariables)throw new TypeError("undefined variable: "+e);return n},n)},t.prototype.set=function(t,n){var r=this.propertyAccessSeq(t),i=this.findContextFor(r[0])||p(this.contexts);r.some(function(t,e){return!m(i)||(e===r.length-1?(i[t]=n,!0):(void 0===i[t]&&(i[t]={}),i=i[t],!1))})},t.prototype.unshift=function(t){return this.contexts.unshift(t)},t.prototype.push=function(t){return this.contexts.push(t)},t.prototype.pop=function(e){if(!arguments.length)return this.contexts.pop();var t=this.contexts.findIndex(function(t){return t===e});if(-1===t)throw new TypeError("scope not found, cannot pop");return this.contexts.splice(t,1)[0]},t.prototype.findContextFor=function(t,e){void 0===e&&(e=function(){return!0});for(var n=this.contexts.length-1;0<=n;n--){var r=this.contexts[n];if(e(r)&&t in r)return r}return null},t.prototype.readProperty=function(t,e){return l(t)?t:(t=u(t))instanceof b?o(t[e])?t[e]():t.hasOwnProperty(e)?t[e]:t.liquidMethodMissing(e):"size"===e?l((n=t).size)&&(g(n)||d(n))?n.length:n.size:t[e];var n},t.prototype.propertyAccessSeq=function(t){t=String(t);for(var e,n=[],r="",i=0;i<t.length;)switch(t[i]){case"[":s();var o=t[i+1];i=/['"]/.test(o)?(S(-1!==(e=t.indexOf(o,i+2)),"unbalanced "+o+": "+t),r=t.slice(i+2,e),s(),e+2):(S(-1!==(e=_(t,i+1)),"unbalanced []: "+t),r=t.slice(i+1,e),/^[+-]?\d+$/.test(r)||(r=String(this.get(r))),s(),e+1);break;case".":s(),i++;break;default:r+=t[i],i++}if(s(),!n.length)throw new TypeError('invalid path:"'+t+'"');return n;function s(){r.length&&n.push(r),r=""}},t}();function _(t,e){for(var n=1,r=e;r<t.length;r++)if("["===t[r]&&n++,"]"===t[r]&&0===--n)return r;return-1}var j=function(){},U=function(){},A=function(){},H=function(){},N=Object.freeze({AssignScope:U,CaptureScope:j,IncrementScope:A,DecrementScope:H,ParseError:x,TokenizationError:T,RenderBreakError:E,AssertionError:q,Drop:b});var z={readFile:function(r){return c(this,void 0,void 0,function(){return h(this,function(t){return[2,new Promise(function(t,e){var n=new XMLHttpRequest;n.onload=function(){200<=n.status&&n.status<300?t(n.responseText):e(new Error(n.statusText))},n.onerror=function(){e(new Error("An error occurred whilst receiving the response."))},n.open("GET",r),n.send()})]})})},resolve:function(t,e,i){return t.length&&"/"!==p(t)&&(t+="/"),function(t,e){var n=document.createElement("base");n.href=t;var r=document.getElementsByTagName("head")[0];r.insertBefore(n,r.firstChild);var i=document.createElement("a");i.href=e;var o=i.href;return r.removeChild(n),o}(t,e).replace(/^(\w+:\/\/[^/]+)(\/[^?]+)/,function(t,e,n){var r=n.split("/").pop();return/\.\w+$/.test(r)?t:e+n+i})},exists:function(){return c(this,void 0,void 0,function(){return h(this,function(t){return[2,!0]})})}};var C,Y,$=function(t,e,n,r,i){this.type="notset",this.col=r,this.line=n,this.raw=t,this.value=t,this.input=e,this.file=i},I=function(s){function t(t,e,n,r,i){var o=s.call(this,t,e,n,r,i)||this;return o.type="html",o.value=t,o}return i(t,s),t}($),B=function(u){function t(t,e,n,r,i,o){var s=u.call(this,t,n,r,i,o)||this;return s.trimLeft="-"===e[0],s.trimRight="-"===p(e),s.value=e.slice(s.trimLeft?1:0,s.trimRight?-1:e.length).trim(),s}return i(t,u),t}($),V=new RegExp(/'[^']*'/.source+"|"+/"[^"]*"/.source),G=new RegExp("(?:"+V.source+"|[^'\"])*"),W=/[+-]?(?:\d+\.?\d*|\.?\d+)/,J=/[\w-]+[?]?/,X=new RegExp("\\[(?:"+V.source+"|[\\w-\\.]+)\\]"),K=new RegExp("(?:"+V.source+"|"+/true|false/.source+"|"+W.source+")"),Q=new RegExp(J.source+"(?:\\."+J.source+"|"+X.source+")*"),Z=new RegExp("(?:"+Q.source+"|"+W.source+")"),tt=new RegExp("\\("+Z.source+"\\.\\."+Z.source+"\\)"),et=new RegExp("\\(("+Z.source+")\\.\\.("+Z.source+")\\)"),nt=new RegExp("(?:"+Q.source+"|"+K.source+"|"+tt.source+")"),rt=new RegExp("(?:"+J.source+")\\s*:\\s*(?:"+nt.source+")"),it=new RegExp("("+J.source+")\\s*:\\s*("+nt.source+")","g"),ot=new RegExp("^\\s*("+J.source+")\\s*([\\s\\S]*?)\\s*$"),st=new RegExp("^"+V.source+"$"),ut=new RegExp("^"+et.source+"$"),at=[/\s+or\s+/,/\s+and\s+/,/==|!=|<=|>=|<|>|\s+contains\s+/],ct=function(a){function t(t,e,n,r,i,o){var s=a.call(this,t,e,n,r,i,o)||this;s.type="tag";var u=s.value.match(ot);if(!u)throw new T("illegal tag syntax",s);return s.name=u[1],s.args=u[2],s}return i(t,a),t}(B),lt=function(u){function t(t,e,n,r,i,o){var s=u.call(this,t,e,n,r,i,o)||this;return s.type="output",s}return i(t,u),t}(B);(Y=C||(C={}))[Y.HTML=0]="HTML",Y[Y.OUTPUT=1]="OUTPUT",Y[Y.TAG=2]="TAG";var ft=function(){function t(t){this.options=F(t)}return t.prototype.tokenize=function(t,e){for(var n=[],r=this.options.tagDelimiterLeft,i=this.options.tagDelimiterRight,o=this.options.outputDelimiterLeft,s=this.options.outputDelimiterRight,u=0,a=1,c=C.HTML,l="",f=0,p=1,h=1;u<t.length;){if("\n"===t[u]&&(a++,f=u+1),c===C.HTML){if(t.substr(u,o.length)===o){l&&n.push(new I(l,t,p,h,e)),p=a,h=u-f+1,u+=(l=o).length,c=C.OUTPUT;continue}if(t.substr(u,r.length)===r){l&&n.push(new I(l,t,p,h,e)),p=a,h=u-f+1,u+=(l=r).length,c=C.TAG;continue}}else{if(c===C.OUTPUT&&t.substr(u,s.length)===s){l+=s,n.push(new lt(l,l.slice(o.length,-s.length),t,p,h,e)),l="",p=a,h=(u+=s.length)-f+1,c=C.HTML;continue}if(t.substr(u,i.length)===i){l+=i,n.push(new ct(l,l.slice(r.length,-i.length),t,p,h,e)),l="",p=a,h=(u+=i.length)-f+1,c=C.HTML;continue}}l+=t[u++]}if(c===C.HTML)return l&&n.push(new I(l,t,p,h,e)),function(s,u){u=v({greedy:!0},u);var a=!1;s.forEach(function(t,e){var n,r,i,o;i=t,o=u,!a&&("tag"===i.type?i.trimLeft||o.trimTagLeft:"output"===i.type?i.trimLeft||o.trimOutputLeft:void 0)&&function(t,e){if(t&&"html"===t.type){var n=e?/\s+$/g:/[\t\r ]*$/g;t.value=t.value.replace(n,"")}}(s[e-1],u.greedy),"tag"===t.type&&"raw"===t.name&&(a=!0),"tag"===t.type&&"endraw"===t.name&&(a=!1),n=t,r=u,!a&&("tag"===n.type?n.trimRight||r.trimTagRight:"output"===n.type?n.trimRight||r.trimOutputRight:void 0)&&function(t,e){if(t&&"html"===t.type){var n=e?/^\s+/g:/^[\t\r ]*\n?/g;t.value=t.value.replace(n,"")}}(s[e+1],u.greedy)})}(n,this.options),n;var d=c===C.OUTPUT?"output":"tag",g=16<l.length?l.slice(0,13)+"...":l;throw new T(d+' "'+g+'" not closed',new $(l,t,p,h,e))},t}(),pt=function(){function t(){}return t.prototype.renderTemplates=function(u,a){return c(this,void 0,void 0,function(){var e,n,r,i,o,s;return h(this,function(t){switch(t.label){case 0:S(a,"unable to evalTemplates: scope undefined"),e="",n=0,r=u,t.label=1;case 1:if(!(n<r.length))return[3,6];i=r[n],t.label=2;case 2:return t.trys.push([2,4,,5]),o=e,[4,i.render(a)];case 3:return e=o+t.sent(),[3,5];case 4:if("RenderBreakError"===(s=t.sent()).name)throw s.resolvedHTML=e,s;throw"RenderError"===s.name?s:new k(s,i);case 5:return n++,[3,1];case 6:return[2,e]}})})},t}();function ht(t){return t&&o(t.equals)}var dt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i(e,t),e.prototype.equals=function(t){return d(t)||g(t)?0===t.length:!!m(t)&&0===Object.keys(t).length},e.prototype.gt=function(){return!1},e.prototype.geq=function(){return!1},e.prototype.lt=function(){return!1},e.prototype.leq=function(){return!1},e.prototype.valueOf=function(){return""},e}(b),gt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.equals=function(t){return!1===t||(!!l(t instanceof b?t.valueOf():t)||(d(t)?/^\s*$/.test(t):e.prototype.equals.call(this,t)))},t}(dt),vt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i(e,t),e.prototype.equals=function(t){return l(t instanceof b?t.valueOf():t)||t instanceof gt},e.prototype.gt=function(){return!1},e.prototype.geq=function(){return!1},e.prototype.lt=function(){return!1},e.prototype.leq=function(){return!1},e.prototype.valueOf=function(){return null},e}(b),mt={"==":function(t,e){return ht(t)?t.equals(e):ht(e)?e.equals(t):t===e},"!=":function(t,e){return ht(t)?!t.equals(e):ht(e)?!e.equals(t):t!==e},">":function(t,e){return ht(t)?t.gt(e):ht(e)?e.lt(t):e<t},"<":function(t,e){return ht(t)?t.lt(e):ht(e)?e.gt(t):t<e},">=":function(t,e){return ht(t)?t.geq(e):ht(e)?e.leq(t):e<=t},"<=":function(t,e){return ht(t)?t.leq(e):ht(e)?e.geq(t):t<=e},contains:function(t,e){return!!t&&("function"==typeof t.indexOf&&-1<t.indexOf(e))},and:function(t,e){return Tt(t)&&Tt(e)},or:function(t,e){return Tt(t)||Tt(e)}};function yt(t,e){var n=function t(e,n){S(n,"unable to parseExp: scope undefined");for(var r,i=at,o=0;o<i.length;o++){var s=i[o],u=new RegExp("^("+G.source+")("+s.source+")("+G.source+")$");if(r=e.match(u)){var a=t(r[1],n);return(0,mt[r[2].trim()])(a,t(r[3],n))}}return(r=e.match(ut))?y(bt(r[1],n),bt(r[2],n)+1):wt(e,n)}(t,e);return n instanceof b?n.valueOf():n}function wt(t,e){return t?"true"===(t=t.trim())||"false"!==t&&("nil"===t||"null"===t?new vt:"empty"===t?new dt:"blank"===t?new gt:isNaN(Number(t))?'"'!==t[0]&&"'"!==t[0]||t[0]!==p(t)?e.get(t):t.slice(1,-1):Number(t)):null}function bt(t,e){var n=wt(t,e);return n instanceof b?n.valueOf():n}function Tt(t){return!xt(t)}function xt(t){return!1===t||null==t}var kt=function(t,e){var n;for(it.lastIndex=0;n=it.exec(t);){var r=n[1],i=n[2];this[r]=bt(i,e)}},Et=function(t){this.token=t},qt=function(s){function u(t,e,n){var r=s.call(this,t)||this;r.name=t.name;var i,o=u.impls[t.name];return S(o,"tag "+t.name+" not found"),r.impl=(i=o,Object.create(i)),r.impl.liquid=n,r.impl.parse&&r.impl.parse(t,e),r}return i(u,s),u.prototype.render=function(r){return c(this,void 0,void 0,function(){var e,n;return h(this,function(t){switch(t.label){case 0:return e=new kt(this.token.args,r),"function"!=typeof(n=this.impl).render?[2,""]:[4,n.render(r,e)];case 1:return[2,a(t.sent())]}})})},u.register=function(t,e){u.impls[t]=e},u.clear=function(){u.impls={}},u.impls={},u}(Et),St=function(){function i(t,e,n){var r=i.impls[t];if(!r&&n)throw new TypeError("undefined filter: "+t);this.name=t,this.impl=r||function(t){return t},this.args=e}return i.prototype.render=function(t,e){var n=this.args.map(function(t){return g(t)?[t[0],bt(t[1],e)]:bt(t,e)});return this.impl.apply(null,[t].concat(n))},i.register=function(t,e){i.impls[t]=e},i.clear=function(){i.impls={}},i.impls={},i}(),Ot=function(){function t(t,e){this.handlers={},this.stopRequested=!1,this.tokens=t,this.parseToken=e}return t.prototype.on=function(t,e){return this.handlers[t]=e,this},t.prototype.trigger=function(t,e){var n=this.handlers[t];return"function"==typeof n&&(n(e),!0)},t.prototype.start=function(){var t;for(this.trigger("start");!this.stopRequested&&(t=this.tokens.shift());)if(!(this.trigger("token",t)||"tag"===t.type&&this.trigger("tag:"+t.name,t))){var e=this.parseToken(t,this.tokens);this.trigger("template",e)}return this.stopRequested||this.trigger("end"),this},t.prototype.stop=function(){return this.stopRequested=!0,this},t}(),Rt=function(){function r(t,e){this.filters=[];var n=r.tokenize(t);this.strictFilters=e,this.initial=n[0],this.parseFilters(n,1)}return r.prototype.parseFilters=function(t,e){for(var n=e;n<t.length;)if("|"===t[n]){for(var r=++n;n<t.length&&"|"!==t[n];)n++;this.parseFilter(t,r,n)}else n++},r.prototype.parseFilter=function(t,e,n){for(var r,i,o=t[e],s=[],u=e+1;u<n+1;u++)u===n||","===t[u]?((r||i)&&s.push(r?[r,i]:i),i=r=void 0):":"===t[u]?(r=i,i=void 0):void 0===i&&(i=t[u]);this.filters.push(new St(o,s,this.strictFilters))},r.prototype.value=function(n){return this.filters.reduce(function(t,e){return e.render(t,n)},yt(this.initial,n))},r.tokenize=function(t){for(var e=[],n=0;n<t.length;){var r=t[n];if('"'===r||"'"===r){var i=n;for(n+=2;n<t.length&&t[n-1]!==r;++n);e.push(t.slice(i,n))}else if(/\s/.test(r))n++;else if(/[|,:]/.test(r))e.push(t[n++]);else{for(i=n++;n<t.length&&!/[|,:\s]/.test(t[n]);++n);e.push(t.slice(i,n))}}return e},r}(),Mt=function(r){function t(t,e){var n=r.call(this,t)||this;return n.value=new Rt(t.value,e),n}return i(t,r),t.prototype.render=function(e){return c(this,void 0,void 0,function(){return h(this,function(t){switch(t.label){case 0:return[4,this.value.value(e)];case 1:return[2,a(t.sent())]}})})},t}(Et),Lt=function(n){function t(t){var e=n.call(this,t)||this;return e.str=t.value,e}return i(t,n),t.prototype.render=function(){return c(this,void 0,void 0,function(){return h(this,function(t){return[2,this.str]})})},t}(Et),Ft=function(){function t(t){this.liquid=t}return t.prototype.parse=function(t){for(var e,n=[];e=t.shift();)n.push(this.parseToken(e,t));return n},t.prototype.parseToken=function(e,t){try{return"tag"===e.type?new qt(e,t,this.liquid):"output"===e.type?new Mt(e,this.liquid.options.strictFilters):new Lt(e)}catch(t){throw new x(t,e)}},t.prototype.parseStream=function(t){var n=this;return new Ot(t,function(t,e){return n.parseToken(t,e)})},t}(),Dt=new RegExp("("+J.source+")\\s*=([^]*)"),Pt={parse:function(t){var e=t.args.match(Dt);S(e,"illegal token "+t.raw),this.key=e[1],this.value=e[2]},render:function(t){var e=new U;return e[this.key]=this.liquid.evalValue(this.value,t),t.push(e),Promise.resolve("")}},_t=function(n){function t(t){var e=n.call(this)||this;return e.i=0,e.length=t,e}return i(t,n),t.prototype.next=function(){this.i++},t.prototype.index0=function(){return this.i},t.prototype.index=function(){return this.i+1},t.prototype.first=function(){return 0===this.i},t.prototype.last=function(){return this.i===this.length-1},t.prototype.rindex=function(){return this.length-this.i},t.prototype.rindex0=function(){return this.length-this.i-1},t.prototype.valueOf=function(){return JSON.stringify(this)},t}(b),jt=new RegExp("^("+J.source+")\\s+in\\s+("+nt.source+")(?:\\s+"+rt.source+")*(?:\\s+(reversed))?(?:\\s+"+rt.source+")*$"),Ut={type:"block",parse:function(t,e){var n,r=this,i=jt.exec(t.args);S(i,"illegal tag: "+t.raw),this.variable=i[1],this.collection=i[2],this.reversed=!!i[3],this.templates=[],this.elseTemplates=[];var o=this.liquid.parser.parseStream(e).on("start",function(){return n=r.templates}).on("tag:else",function(){return n=r.elseTemplates}).on("tag:endfor",function(){return o.stop()}).on("template",function(t){return n.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});o.start()},render:function(f,p){return c(this,void 0,void 0,function(){var e,n,r,i,o,s,u,a,c,l;return h(this,function(t){switch(t.label){case 0:if(g(e=yt(this.collection,f))||(d(e)&&0<e.length?e=[e]:m(e)&&(e=Object.keys(e).map(function(t){return[t,e[t]]}))),!g(e)||!e.length)return[2,this.liquid.renderer.renderTemplates(this.elseTemplates,f)];n=p.offset||0,r=void 0===p.limit?e.length:p.limit,e=e.slice(n,n+r),this.reversed&&e.reverse(),i={forloop:new _t(e.length)},f.push(i),o="",s=0,u=e,t.label=1;case 1:if(!(s<u.length))return[3,7];a=u[s],i[this.variable]=a,t.label=2;case 2:return t.trys.push([2,4,,5]),c=o,[4,this.liquid.renderer.renderTemplates(this.templates,f)];case 3:return o=c+t.sent(),[3,5];case 4:if("RenderBreakError"!==(l=t.sent()).name)throw l;return o+=l.resolvedHTML,"break"===l.message?[3,7]:[3,5];case 5:i.forloop.next(),t.label=6;case 6:return s++,[3,1];case 7:return f.pop(),[2,o]}})})}},At=new RegExp("("+J.source+")"),Ht={parse:function(t,e){var n=this,r=t.args.match(At);S(r,t.args+" not valid identifier"),this.variable=r[1],this.templates=[];var i=this.liquid.parser.parseStream(e);i.on("tag:endcapture",function(){return i.stop()}).on("template",function(t){return n.templates.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")}),i.start()},render:function(r){return c(this,void 0,void 0,function(){var e,n;return h(this,function(t){switch(t.label){case 0:return[4,this.liquid.renderer.renderTemplates(this.templates,r)];case 1:return e=t.sent(),(n=new j)[this.variable]=e,r.push(n),[2]}})})}},Nt={parse:function(t,e){var n=this;this.cond=t.args,this.cases=[],this.elseTemplates=[];var r=[],i=this.liquid.parser.parseStream(e).on("tag:when",function(t){n.cases.push({val:t.args,templates:r=[]})}).on("tag:else",function(){return r=n.elseTemplates}).on("tag:endcase",function(){return i.stop()}).on("template",function(t){return r.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});i.start()},render:function(t){for(var e=0;e<this.cases.length;e++){var n=this.cases[e];if(yt(n.val,t)===yt(this.cond,t))return this.liquid.renderer.renderTemplates(n.templates,t)}return this.liquid.renderer.renderTemplates(this.elseTemplates,t)}},zt={parse:function(t,e){var n=this.liquid.parser.parseStream(e);n.on("token",function(t){"endcomment"===t.name&&n.stop()}).on("end",function(){throw new Error("tag "+t.raw+" not closed")}),n.start()}},Ct=/[^\s,]+/,Yt=new RegExp("with\\s+("+nt.source+")"),$t={parse:function(t){var e=Ct.exec(t.args);e&&(this.staticValue=e[0]),(e=nt.exec(t.args))&&(this.value=e[0]),(e=Yt.exec(t.args))&&(this.with=e[1])},render:function(u,a){return c(this,void 0,void 0,function(){var e,n,r,i,o,s;return h(this,function(t){switch(t.label){case 0:return u.opts.dynamicPartials?st.exec(this.value)?(n=this.value.slice(1,-1),[4,this.liquid.parseAndRender(n,u.getAll(),u.opts)]):[3,2]:[3,4];case 1:return e=t.sent(),[3,3];case 2:e=bt(this.value,u),t.label=3;case 3:return[3,5];case 4:e=this.staticValue,t.label=5;case 5:return S(e,"cannot include with empty filename"),r=u.blocks,i=u.blockMode,u.blocks={},u.blockMode=D.OUTPUT,this.with&&(a[e]=bt(this.with,u)),[4,this.liquid.getTemplate(e,u.opts)];case 6:return o=t.sent(),u.push(a),[4,this.liquid.renderer.renderTemplates(o,u)];case 7:return s=t.sent(),u.pop(a),u.blocks=r,u.blockMode=i,[2,s]}})})}},It={parse:function(t){var e=t.args.match(J);S(e,"illegal identifier "+t.args),this.variable=e[0]},render:function(t){var e=t.findContextFor(this.variable,function(t){return!(t instanceof j||t instanceof U)});return e||(e=new H,t.unshift(e)),"number"!=typeof e[this.variable]&&(e[this.variable]=0),--e[this.variable]}},Bt=new RegExp("^(?:("+nt.source+")\\s*:\\s*)?(.*)$"),Vt=new RegExp(nt.source,"g"),Gt={parse:function(t){var e=Bt.exec(t.args);S(e,"illegal tag: "+t.raw),this.group=e[1]||"";var n=e[2];for(this.candidates=[];e=Vt.exec(n);)this.candidates.push(e[0]);S(this.candidates.length,"empty candidates: "+t.raw)},render:function(t){var e="cycle:"+bt(this.group,t)+":"+this.candidates.join(","),n=t.groups,r=n[e];void 0===r&&(r=n[e]=0);var i=this.candidates[r];return r=(r+1)%this.candidates.length,n[e]=r,bt(i,t)}},Wt={parse:function(t,e){var n,r=this;this.branches=[],this.elseTemplates=[];var i=this.liquid.parser.parseStream(e).on("start",function(){return r.branches.push({cond:t.args,templates:n=[]})}).on("tag:elsif",function(t){r.branches.push({cond:t.args,templates:n=[]})}).on("tag:else",function(){return n=r.elseTemplates}).on("tag:endif",function(){return i.stop()}).on("template",function(t){return n.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});i.start()},render:function(t){for(var e=0,n=this.branches;e<n.length;e++){var r=n[e];if(Tt(yt(r.cond,t)))return this.liquid.renderer.renderTemplates(r.templates,t)}return this.liquid.renderer.renderTemplates(this.elseTemplates,t)}},Jt={parse:function(t){var e=t.args.match(J);S(e,"illegal identifier "+t.args),this.variable=e[0]},render:function(t){var e=t.findContextFor(this.variable,function(t){return!(t instanceof j||t instanceof U)});e||(e=new A,t.unshift(e)),"number"!=typeof e[this.variable]&&(e[this.variable]=0);var n=e[this.variable];return e[this.variable]++,n}},Xt=/\S+/,Kt={parse:function(t,e){var n=Xt.exec(t.args);n&&(this.staticLayout=n[0]),(n=nt.exec(t.args))&&(this.layout=n[0]),this.tpls=this.liquid.parser.parse(e)},render:function(o,s){return c(this,void 0,void 0,function(){var e,n,r,i;return h(this,function(t){switch(t.label){case 0:return S(e=o.opts.dynamicPartials?bt(this.layout,o):this.staticLayout,"cannot apply layout with empty filename"),o.blockMode=D.STORE,[4,this.liquid.renderer.renderTemplates(this.tpls,o)];case 1:return n=t.sent(),void 0===o.blocks[""]&&(o.blocks[""]=n),[4,this.liquid.getTemplate(e,o.opts)];case 2:return r=t.sent(),o.push(s),o.blockMode=D.OUTPUT,[4,this.liquid.renderer.renderTemplates(r,o)];case 3:return i=t.sent(),o.pop(s),[2,i]}})})}},Qt={parse:function(t,e){var n=this,r=/\w+/.exec(t.args);this.block=r?r[0]:"",this.tpls=[];var i=this.liquid.parser.parseStream(e).on("tag:endblock",function(){return i.stop()}).on("template",function(t){return n.tpls.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});i.start()},render:function(i){return c(this,void 0,void 0,function(){var e,n,r;return h(this,function(t){switch(t.label){case 0:return void 0===(e=i.blocks[this.block])?[3,1]:(r=e,[3,3]);case 1:return[4,this.liquid.renderer.renderTemplates(this.tpls,i)];case 2:r=t.sent(),t.label=3;case 3:return n=r,i.blockMode===D.STORE?(i.blocks[this.block]=n,[2,""]):[2,n]}})})}},Zt={parse:function(t,e){var n=this;this.tokens=[];var r=this.liquid.parser.parseStream(e);r.on("token",function(t){"endraw"===t.name?r.stop():n.tokens.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")}),r.start()},render:function(){return this.tokens.map(function(t){return t.raw}).join("")}},te=function(r){function t(t,e){var n=r.call(this,t)||this;return n.length=t,n.cols=e,n}return i(t,r),t.prototype.row=function(){return Math.floor(this.i/this.cols)+1},t.prototype.col0=function(){return this.i%this.cols},t.prototype.col=function(){return this.col0()+1},t.prototype.col_first=function(){return 0===this.col0()},t.prototype.col_last=function(){return this.col()===this.cols},t}(_t),ee=new RegExp("^("+J.source+")\\s+in\\s+("+nt.source+")(?:\\s+"+rt.source+")*$"),ne={assign:Pt,for:Ut,capture:Ht,case:Nt,comment:zt,include:$t,decrement:It,increment:Jt,cycle:Gt,if:Wt,layout:Kt,block:Qt,raw:Zt,tablerow:{parse:function(t,e){var n,r=this,i=ee.exec(t.args);S(i,"illegal tag: "+t.raw),this.variable=i[1],this.collection=i[2],this.templates=[];var o=this.liquid.parser.parseStream(e).on("start",function(){return n=r.templates}).on("tag:endtablerow",function(){return o.stop()}).on("template",function(t){return n.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});o.start()},render:function(l,f){return c(this,void 0,void 0,function(){var e,n,r,i,o,s,u,a,c;return h(this,function(t){switch(t.label){case 0:e=yt(this.collection,l)||[],n=f.offset||0,r=void 0===f.limit?e.length:f.limit,e=e.slice(n,n+r),i=f.cols||e.length,o=new te(e.length,i),s={tablerowloop:o},l.push(s),u="",a=0,t.label=1;case 1:return a<e.length?(s[this.variable]=e[a],0===o.col0()&&(1!==o.row()&&(u+="</tr>"),u+='<tr class="row'+o.row()+'">'),u+='<td class="col'+o.col()+'">',c=u,[4,this.liquid.renderer.renderTemplates(this.templates,l)]):[3,4];case 2:u=c+t.sent(),u+="</td>",t.label=3;case 3:return a++,o.next(),[3,1];case 4:return e.length&&(u+="</tr>"),l.pop(s),[2,u]}})})}},unless:{parse:function(t,e){var n,r=this;this.templates=[],this.elseTemplates=[];var i=this.liquid.parser.parseStream(e).on("start",function(){n=r.templates,r.cond=t.args}).on("tag:else",function(){return n=r.elseTemplates}).on("tag:endunless",function(){return i.stop()}).on("template",function(t){return n.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});i.start()},render:function(t){return xt(yt(this.cond,t))?this.liquid.renderer.renderTemplates(this.templates,t):this.liquid.renderer.renderTemplates(this.elseTemplates,t)}},break:{render:function(){return c(this,void 0,void 0,function(){return h(this,function(t){throw new E("break")})})}},continue:{render:function(){return c(this,void 0,void 0,function(){return h(this,function(t){throw new E("continue")})})}}},re={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&#34;","'":"&#39;"},ie={"&amp;":"&","&lt;":"<","&gt;":">","&#34;":'"',"&#39;":"'"};function oe(t){return String(t).replace(/&|<|>|"|'/g,function(t){return re[t]})}var se={escape:oe,escape_once:function(t){return oe(String(t).replace(/&(amp|lt|gt|#34|#39);/g,function(t){return ie[t]}))},newline_to_br:function(t){return t.replace(/\n/g,"<br />")},strip_html:function(t){return t.replace(/<script.*?<\/script>|<!--.*?-->|<style.*?<\/style>|<.*?>/g,"")}},ue={append:function(t,e){return t+e},prepend:function(t,e){return e+t},capitalize:function(t){return String(t).charAt(0).toUpperCase()+t.slice(1)},lstrip:function(t){return String(t).replace(/^\s+/,"")},downcase:function(t){return t.toLowerCase()},upcase:function(t){return String(t).toUpperCase()},remove:function(t,e){return t.split(e).join("")},remove_first:function(t,e){return t.replace(e,"")},replace:function(t,e,n){return String(t).split(e).join(n)},replace_first:function(t,e,n){return String(t).replace(e,n)},rstrip:function(t){return String(t).replace(/\s+$/,"")},split:function(t,e){return String(t).split(e)},strip:function(t){return String(t).trim()},strip_newlines:function(t){return String(t).replace(/\n/g,"")},truncate:function(t,e,n){return void 0===e&&(e=50),void 0===n&&(n="..."),(t=String(t)).length<=e?t:t.substr(0,e-n.length)+n},truncatewords:function(t,e,n){void 0===e&&(e=15),void 0===n&&(n="...");var r=t.split(/\s+/),i=r.slice(0,e).join(" ");return r.length>=e&&(i+=n),i}},ae={abs:function(t){return Math.abs(t)},ceil:function(t){return Math.ceil(t)},divided_by:function(t,e){return t/e},floor:function(t){return Math.floor(t)},minus:function(t,e){return t-e},modulo:function(t,e){return t%e},round:function(t,e){void 0===e&&(e=0);var n=Math.pow(10,e);return Math.round(t*n)/n},plus:function(t,e){return Number(t)+Number(e)},times:function(t,e){return t*e}},ce={url_decode:function(t){return t.split("+").map(decodeURIComponent).join(" ")},url_encode:function(t){return t.split(" ").map(encodeURIComponent).join("+")}},le={join:function(t,e){return t.join(void 0===e?" ":e)},last:function(t){return p(t)},first:function(t){return t[0]},map:function(t,e){return t.map(function(t){return t[e]})},reverse:function(t){return t.reverse()},sort:function(t,e){return t.sort(e)},size:function(t){return t.length},concat:function(t,e){return Array.prototype.concat.call(t,e)},slice:function(t,e,n){return void 0===n&&(n=1),t.slice(e,e+n)},uniq:function(t){var e={};return(t||[]).filter(function(t){return!e.hasOwnProperty(String(t))&&(e[String(t)]=!0)})}},fe=["January","February","March","April","May","June","July","August","September","October","November","December"],pe=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],he=fe.map(ve),de=pe.map(ve),ge={1:"st",2:"nd",3:"rd",default:"th"};function ve(t){return t.slice(0,3)}var me={daysInMonth:function(t){return[31,me.isLeapYear(t)?29:28,31,30,31,30,31,31,30,31,30,31]},getDayOfYear:function(t){for(var e=0,n=0;n<t.getMonth();++n)e+=me.daysInMonth(t)[n];return e+t.getDate()},getWeekOfYear:function(t,e){var n=this.getDayOfYear(t)+(e-t.getDay()),r=7-new Date(t.getFullYear(),0,1).getDay()+e;return w(String(Math.floor((n-r)/7)+1),2,"0")},isLeapYear:function(t){var e=t.getFullYear();return!(0!=(3&e)||!(e%100||e%400==0&&e))},getSuffix:function(t){var e=t.getDate().toString(),n=parseInt(e.slice(-1));return ge[n]||ge.default},century:function(t){return parseInt(t.getFullYear().toString().substring(0,2),10)}},ye={a:function(t){return de[t.getDay()]},A:function(t){return pe[t.getDay()]},b:function(t){return he[t.getMonth()]},B:function(t){return fe[t.getMonth()]},c:function(t){return t.toLocaleString()},C:function(t){return me.century(t)},d:function(t){return w(t.getDate(),2,"0")},e:function(t){return w(t.getDate(),2)},H:function(t){return w(t.getHours(),2,"0")},I:function(t){return w(String(t.getHours()%12||12),2,"0")},j:function(t){return w(me.getDayOfYear(t),3,"0")},k:function(t){return w(t.getHours(),2)},l:function(t){return w(String(t.getHours()%12||12),2)},L:function(t){return w(t.getMilliseconds(),3,"0")},m:function(t){return w(t.getMonth()+1,2,"0")},M:function(t){return w(t.getMinutes(),2,"0")},p:function(t){return t.getHours()<12?"AM":"PM"},P:function(t){return t.getHours()<12?"am":"pm"},q:function(t){return me.getSuffix(t)},s:function(t){return Math.round(t.valueOf()/1e3)},S:function(t){return w(t.getSeconds(),2,"0")},u:function(t){return t.getDay()||7},U:function(t){return me.getWeekOfYear(t,0)},w:function(t){return t.getDay()},W:function(t){return me.getWeekOfYear(t,1)},x:function(t){return t.toLocaleDateString()},X:function(t){return t.toLocaleTimeString()},y:function(t){return t.getFullYear().toString().substring(2,4)},Y:function(t){return t.getFullYear()},z:function(t){var e=t.getTimezoneOffset()/60*100;return(0<e?"-":"+")+w(String(Math.abs(e)),4,"0")},"%":function(){return"%"}};ye.h=ye.b,ye.N=ye.L;var we=v({},se,ue,ae,ce,{date:function(t,e){var n,r=t;return"now"===t?r=new Date:d(t)&&(r=new Date(t)),(n=r)instanceof Date&&!isNaN(n.getTime())?function(t,e){for(var n="",r=e;;){var i=/%./g,o=i.exec(r);if(!o)return n+r;n+=r.slice(0,i.lastIndex-2),r=r.slice(i.lastIndex);var s=o[0].charAt(1),u=ye[s];n+=u?u(t):"%"+s}}(r,e):t}},{default:function(t,e){return Tt(t)?t:e}},le);return function(){function e(t){void 0===t&&(t={});var n=this;this.cache={},this.options=F(L(t)),this.parser=new Ft(this),this.renderer=new pt,this.tokenizer=new ft(this.options),f(ne,function(t,e){return n.registerTag(e,t)}),f(we,function(t,e){return n.registerFilter(e,t)})}return e.prototype.parse=function(t,e){var n=this.tokenizer.tokenize(t,e);return this.parser.parse(n)},e.prototype.render=function(t,e,n){var r=v({},this.options,L(n)),i=new P(e,r);return this.renderer.renderTemplates(t,i)},e.prototype.parseAndRender=function(n,r,i){return c(this,void 0,void 0,function(){var e;return h(this,function(t){switch(t.label){case 0:return[4,this.parse(n)];case 1:return e=t.sent(),[2,this.render(e,r,i)]}})})},e.prototype.getTemplate=function(f,p){return c(this,void 0,void 0,function(){var e,n,r,i,o,s,u,a,c,l=this;return h(this,function(t){switch(t.label){case 0:e=L(p),n=e.root?e.root.concat(this.options.root):this.options.root,r=n.map(function(t){return z.resolve(t,f,l.options.extname)}),i=0,o=r,t.label=1;case 1:return i<o.length?(s=o[i],[4,z.exists(s)]):[3,5];case 2:return t.sent()?this.options.cache&&this.cache[s]?[2,this.cache[s]]:(a=this.parse,[4,z.readFile(s)]):[3,4];case 3:return u=a.apply(this,[t.sent(),s]),this.options.cache&&(this.cache[s]=u),[2,u];case 4:return i++,[3,1];case 5:throw(c=new Error("ENOENT")).message='ENOENT: Failed to lookup "'+f+'" in "'+n+'"',c.code="ENOENT",c}})})},e.prototype.renderFile=function(r,i,o){return c(this,void 0,void 0,function(){var e,n;return h(this,function(t){switch(t.label){case 0:return e=L(o),[4,this.getTemplate(r,e)];case 1:return n=t.sent(),[2,this.render(n,i,o)]}})})},e.prototype.evalValue=function(t,e){return new Rt(t,this.options.strictFilters).value(e)},e.prototype.registerFilter=function(t,e){return St.register(t,e)},e.prototype.registerTag=function(t,e){return qt.register(t,e)},e.prototype.plugin=function(t){return t.call(this,e)},e.prototype.express=function(){var i=this;return function(t,e,n){var r={root:this.root};i.renderFile(t,e,r).then(function(t){return n(null,t)},n)}},(e.default=e).isTruthy=Tt,e.isFalsy=xt,e.evalExp=yt,e.evalValue=bt,e.Types=N,e}()});
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t=t||self).Liquid=e()}(this,function(){"use strict";var r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)};function i(t,e){function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var v=function(){return(v=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var i in e=arguments[n])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}).apply(this,arguments)};function d(o,s,u,a){return new(u||(u=Promise))(function(t,e){function n(t){try{i(a.next(t))}catch(t){e(t)}}function r(t){try{i(a.throw(t))}catch(t){e(t)}}function i(e){e.done?t(e.value):new u(function(t){t(e.value)}).then(n,r)}i((a=a.apply(o,s||[])).next())})}function g(n,r){var i,o,s,t,u={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return t={next:e(0),throw:e(1),return:e(2)},"function"==typeof Symbol&&(t[Symbol.iterator]=function(){return this}),t;function e(e){return function(t){return function(e){if(i)throw new TypeError("Generator is already executing.");for(;u;)try{if(i=1,o&&(s=2&e[0]?o.return:e[0]?o.throw||((s=o.return)&&s.call(o),0):o.next)&&!(s=s.call(o,e[1])).done)return s;switch(o=0,s&&(e=[2&e[0],s.value]),e[0]){case 0:case 1:s=e;break;case 4:return u.label++,{value:e[1],done:!1};case 5:u.label++,o=e[1],e=[0];continue;case 7:e=u.ops.pop(),u.trys.pop();continue;default:if(!(s=0<(s=u.trys).length&&s[s.length-1])&&(6===e[0]||2===e[0])){u=0;continue}if(3===e[0]&&(!s||e[1]>s[0]&&e[1]<s[3])){u.label=e[1];break}if(6===e[0]&&u.label<s[1]){u.label=s[1],s=e;break}if(s&&u.label<s[2]){u.label=s[2],u.ops.push(e);break}s[2]&&u.ops.pop(),u.trys.pop();continue}e=r.call(n,u)}catch(t){e=[6,t],o=0}finally{i=s=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}([e,t])}}}var e=Object.prototype.toString;function p(t){return"[object String]"===e.call(t)}function o(t){return"function"==typeof t}function a(t){return u(t)?"":(t=s(t),String(t))}function s(t){return o(t.toLiquid)?s(t.toLiquid()):t}function u(t){return null==t}function m(t){return"[object Array]"===e.call(t)}function c(t,e){for(var n in t=t||{})if(t.hasOwnProperty(n)&&!1===e(t[n],n,t))break;return t}function l(t){return t[t.length-1]}function y(t){var e=typeof t;return null!==t&&("object"===e||"function"===e)}function w(t,e,n){void 0===n&&(n=1);for(var r=[],i=t;i<e;i+=n)r.push(i);return r}function f(t,e,n){void 0===n&&(n=" ");for(var r=e-(t=String(t)).length;0<r--;)t=n+t;return t}var h=function(){function t(){}return t.prototype.valueOf=function(){},t.prototype.liquidMethodMissing=function(t){},t}(),t=function(r){function t(t,e){var n=r.call(this,t.message)||this;return n.originalError=t,n.token=e,n}return i(t,r),t.prototype.update=function(){var i,o,t,s,e=this.originalError,n=(i=this.token,o=i.input.split("\n"),t=Math.max(i.line-2,1),s=Math.min(i.line+3,o.length),w(t,s+1).map(function(t){var e=t===i.line?">> ":" ",n=f(String(t),String(s).length),r=o[t-1];return""+e+n+"| "+r}).join("\n"));this.message=function(t,e){e.file&&(t+=", file:"+e.file);return t+=", line:"+e.line+", col:"+e.col}(e.message,this.token),this.stack=this.message+"\n"+n+"\n"+this.stack+"\nFrom "+e.stack},t}(Error),b=function(r){function t(t,e){var n=r.call(this,new Error(t),e)||this;return n.name="TokenizationError",r.prototype.update.call(n),n}return i(t,r),t}(t),n=function(r){function t(t,e){var n=r.call(this,t,e)||this;return n.name="ParseError",n.message=t.message,r.prototype.update.call(n),n}return i(t,r),t}(t),T=function(r){function t(t,e){var n=r.call(this,t,e.token)||this;return n.name="RenderError",n.message=t.message,r.prototype.update.call(n),n}return i(t,r),t}(t),x=function(n){function t(t){var e=n.call(this,t)||this;return e.resolvedHTML="",e.name="RenderBreakError",e.message=t+"",e}return i(t,n),t}(Error),k=function(n){function t(t){var e=n.call(this,t)||this;return e.name="AssertionError",e.message=t+"",e}return i(t,n),t}(Error);function E(t,e){if(!t)throw new k(e=e||"expect "+t+" to be true")}var S,q,O={root:["."],cache:!1,extname:"",dynamicPartials:!0,trimTagRight:!1,trimTagLeft:!1,trimOutputRight:!1,trimOutputLeft:!1,greedy:!0,tagDelimiterLeft:"{%",tagDelimiterRight:"%}",outputDelimiterLeft:"{{",outputDelimiterRight:"}}",strictFilters:!1,strictVariables:!1};function R(t){var e;return(t=t||{}).hasOwnProperty("root")&&(t.root=m(e=t.root)?e:p(e)?[e]:[]),t}function M(t){return v({},O,t)}(q=S||(S={}))[q.OUTPUT=0]="OUTPUT",q[q.STORE=1]="STORE";var L=S,F=function(){function t(t,e){void 0===t&&(t={}),this.blocks={},this.groups={},this.blockMode=L.OUTPUT,this.opts=M(e),this.contexts=[t||{}]}return t.prototype.getAll=function(){return this.contexts.reduce(function(t,e){return v(t,e)},{})},t.prototype.get=function(s){return d(this,void 0,void 0,function(){var e,n,r,i,o;return g(this,function(t){switch(t.label){case 0:return[4,this.propertyAccessSeq(s)];case 1:for(e=t.sent(),n=this.findContextFor(e[0])||l(this.contexts),r=0,i=e;r<i.length;r++)if(o=i[r],u(n=this.readProperty(n,o))&&this.opts.strictVariables)throw new TypeError("undefined variable: "+o);return[2,n]}})})},t.prototype.set=function(e,i){return d(this,void 0,void 0,function(){var n,r;return g(this,function(t){switch(t.label){case 0:return[4,this.propertyAccessSeq(e)];case 1:return n=t.sent(),r=this.findContextFor(n[0])||l(this.contexts),n.some(function(t,e){return!y(r)||(e===n.length-1?(r[t]=i,!0):(void 0===r[t]&&(r[t]={}),r=r[t],!1))}),[2]}})})},t.prototype.unshift=function(t){return this.contexts.unshift(t)},t.prototype.push=function(t){return this.contexts.push(t)},t.prototype.pop=function(e){if(!arguments.length)return this.contexts.pop();var t=this.contexts.findIndex(function(t){return t===e});if(-1===t)throw new TypeError("scope not found, cannot pop");return this.contexts.splice(t,1)[0]},t.prototype.findContextFor=function(t,e){void 0===e&&(e=function(){return!0});for(var n=this.contexts.length-1;0<=n;n--){var r=this.contexts[n];if(e(r)&&t in r)return r}return null},t.prototype.readProperty=function(t,e){return u(t)?t:(t=s(t))instanceof h?o(t[e])?t[e]():t.hasOwnProperty(e)?t[e]:t.liquidMethodMissing(e):"size"===e?u((n=t).size)&&(m(n)||p(n))?n.length:n.size:t[e];var n},t.prototype.propertyAccessSeq=function(a){return d(this,void 0,void 0,function(){function e(){r.length&&n.push(r),r=""}var n,r,i,o,s,u;return g(this,function(t){switch(t.label){case 0:a=String(a),n=[],r="",o=0,t.label=1;case 1:if(!(o<a.length))return[3,10];switch(a[o]){case"[":return[3,2];case".":return[3,7]}return[3,8];case 2:return e(),s=a[o+1],/['"]/.test(s)?(E(-1!==(i=a.indexOf(s,o+2)),"unbalanced "+s+": "+a),r=a.slice(o+2,i),e(),o=i+2,[3,6]):[3,3];case 3:return E(-1!==(i=function(t,e){for(var n=1,r=e;r<t.length;r++)if("["===t[r]&&n++,"]"===t[r]&&0===--n)return r;return-1}(a,o+1)),"unbalanced []: "+a),r=a.slice(o+1,i),/^[+-]?\d+$/.test(r)?[3,5]:(u=String,[4,this.get(r)]);case 4:r=u.apply(void 0,[t.sent()]),t.label=5;case 5:e(),o=i+1,t.label=6;case 6:return[3,9];case 7:return e(),o++,[3,9];case 8:r+=a[o],o++,t.label=9;case 9:return[3,1];case 10:if(e(),!n.length)throw new TypeError('invalid path:"'+a+'"');return[2,n]}})})},t}();var D=function(){},P=function(){},U=function(){},j=function(){},A=Object.freeze({AssignScope:P,CaptureScope:D,IncrementScope:U,DecrementScope:j,ParseError:n,TokenizationError:b,RenderBreakError:x,AssertionError:k,Drop:h});var _={readFile:function(r){return d(this,void 0,void 0,function(){return g(this,function(t){return[2,new Promise(function(t,e){var n=new XMLHttpRequest;n.onload=function(){200<=n.status&&n.status<300?t(n.responseText):e(new Error(n.statusText))},n.onerror=function(){e(new Error("An error occurred whilst receiving the response."))},n.open("GET",r),n.send()})]})})},resolve:function(t,e,i){return t.length&&"/"!==l(t)&&(t+="/"),function(t,e){var n=document.createElement("base");n.href=t;var r=document.getElementsByTagName("head")[0];r.insertBefore(n,r.firstChild);var i=document.createElement("a");i.href=e;var o=i.href;return r.removeChild(n),o}(t,e).replace(/^(\w+:\/\/[^/]+)(\/[^?]+)/,function(t,e,n){var r=n.split("/").pop();return/\.\w+$/.test(r)?t:e+n+i})},exists:function(){return d(this,void 0,void 0,function(){return g(this,function(t){return[2,!0]})})}};var H,N,z=function(t,e,n,r,i){this.type="notset",this.col=r,this.line=n,this.raw=t,this.value=t,this.input=e,this.file=i},C=function(s){function t(t,e,n,r,i){var o=s.call(this,t,e,n,r,i)||this;return o.type="html",o.value=t,o}return i(t,s),t}(z),Y=function(u){function t(t,e,n,r,i,o){var s=u.call(this,t,n,r,i,o)||this;return s.trimLeft="-"===e[0],s.trimRight="-"===l(e),s.value=e.slice(s.trimLeft?1:0,s.trimRight?-1:e.length).trim(),s}return i(t,u),t}(z),$=new RegExp(/'[^']*'/.source+"|"+/"[^"]*"/.source),I=new RegExp("(?:"+$.source+"|[^'\"])*"),B=/[+-]?(?:\d+\.?\d*|\.?\d+)/,V=/[\w-]+[?]?/,G=new RegExp("\\[(?:"+$.source+"|[\\w-\\.]+)\\]"),W=new RegExp("(?:"+$.source+"|"+/true|false/.source+"|"+B.source+")"),J=new RegExp(V.source+"(?:\\."+V.source+"|"+G.source+")*"),X=new RegExp("(?:"+J.source+"|"+B.source+")"),K=new RegExp("\\("+X.source+"\\.\\."+X.source+"\\)"),Q=new RegExp("\\(("+X.source+")\\.\\.("+X.source+")\\)"),Z=new RegExp("(?:"+J.source+"|"+W.source+"|"+K.source+")"),tt=new RegExp("(?:"+V.source+")\\s*:\\s*(?:"+Z.source+")"),et=new RegExp("("+V.source+")\\s*:\\s*("+Z.source+")","g"),nt=new RegExp("^\\s*("+V.source+")\\s*([\\s\\S]*?)\\s*$"),rt=new RegExp("^"+$.source+"$"),it=new RegExp("^"+Q.source+"$"),ot=[/\s+or\s+/,/\s+and\s+/,/==|!=|<=|>=|<|>|\s+contains\s+/],st=function(a){function t(t,e,n,r,i,o){var s=a.call(this,t,e,n,r,i,o)||this;s.type="tag";var u=s.value.match(nt);if(!u)throw new b("illegal tag syntax",s);return s.name=u[1],s.args=u[2],s}return i(t,a),t}(Y),ut=function(u){function t(t,e,n,r,i,o){var s=u.call(this,t,e,n,r,i,o)||this;return s.type="output",s}return i(t,u),t}(Y);(N=H||(H={}))[N.HTML=0]="HTML",N[N.OUTPUT=1]="OUTPUT",N[N.TAG=2]="TAG";var at=function(){function t(t){this.options=M(t)}return t.prototype.tokenize=function(t,e){for(var n=[],r=this.options.tagDelimiterLeft,i=this.options.tagDelimiterRight,o=this.options.outputDelimiterLeft,s=this.options.outputDelimiterRight,u=0,a=1,c=H.HTML,l="",f=0,h=1,p=1;u<t.length;){if("\n"===t[u]&&(a++,f=u+1),c===H.HTML){if(t.substr(u,o.length)===o){l&&n.push(new C(l,t,h,p,e)),h=a,p=u-f+1,u+=(l=o).length,c=H.OUTPUT;continue}if(t.substr(u,r.length)===r){l&&n.push(new C(l,t,h,p,e)),h=a,p=u-f+1,u+=(l=r).length,c=H.TAG;continue}}else{if(c===H.OUTPUT&&t.substr(u,s.length)===s){l+=s,n.push(new ut(l,l.slice(o.length,-s.length),t,h,p,e)),l="",h=a,p=(u+=s.length)-f+1,c=H.HTML;continue}if(t.substr(u,i.length)===i){l+=i,n.push(new st(l,l.slice(r.length,-i.length),t,h,p,e)),l="",h=a,p=(u+=i.length)-f+1,c=H.HTML;continue}}l+=t[u++]}if(c===H.HTML)return l&&n.push(new C(l,t,h,p,e)),function(s,u){u=v({greedy:!0},u);var a=!1;s.forEach(function(t,e){var n,r,i,o;i=t,o=u,!a&&("tag"===i.type?i.trimLeft||o.trimTagLeft:"output"===i.type?i.trimLeft||o.trimOutputLeft:void 0)&&function(t,e){if(t&&"html"===t.type){var n=e?/\s+$/g:/[\t\r ]*$/g;t.value=t.value.replace(n,"")}}(s[e-1],u.greedy),"tag"===t.type&&"raw"===t.name&&(a=!0),"tag"===t.type&&"endraw"===t.name&&(a=!1),n=t,r=u,!a&&("tag"===n.type?n.trimRight||r.trimTagRight:"output"===n.type?n.trimRight||r.trimOutputRight:void 0)&&function(t,e){if(t&&"html"===t.type){var n=e?/^\s+/g:/^[\t\r ]*\n?/g;t.value=t.value.replace(n,"")}}(s[e+1],u.greedy)})}(n,this.options),n;var d=c===H.OUTPUT?"output":"tag",g=16<l.length?l.slice(0,13)+"...":l;throw new b(d+' "'+g+'" not closed',new z(l,t,h,p,e))},t}(),ct=function(){function t(){}return t.prototype.renderTemplates=function(u,a){return d(this,void 0,void 0,function(){var e,n,r,i,o,s;return g(this,function(t){switch(t.label){case 0:E(a,"unable to evalTemplates: scope undefined"),e="",n=0,r=u,t.label=1;case 1:if(!(n<r.length))return[3,6];i=r[n],t.label=2;case 2:return t.trys.push([2,4,,5]),o=e,[4,i.render(a)];case 3:return e=o+t.sent(),[3,5];case 4:if("RenderBreakError"===(s=t.sent()).name)throw s.resolvedHTML=e,s;throw"RenderError"===s.name?s:new T(s,i);case 5:return n++,[3,1];case 6:return[2,e]}})})},t}();function lt(t){return t&&o(t.equals)}var ft=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i(e,t),e.prototype.equals=function(t){return p(t)||m(t)?0===t.length:!!y(t)&&0===Object.keys(t).length},e.prototype.gt=function(){return!1},e.prototype.geq=function(){return!1},e.prototype.lt=function(){return!1},e.prototype.leq=function(){return!1},e.prototype.valueOf=function(){return""},e}(h),ht=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.prototype.equals=function(t){return!1===t||(!!u(t instanceof h?t.valueOf():t)||(p(t)?/^\s*$/.test(t):e.prototype.equals.call(this,t)))},t}(ft),pt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i(e,t),e.prototype.equals=function(t){return u(t instanceof h?t.valueOf():t)||t instanceof ht},e.prototype.gt=function(){return!1},e.prototype.geq=function(){return!1},e.prototype.lt=function(){return!1},e.prototype.leq=function(){return!1},e.prototype.valueOf=function(){return null},e}(h),dt={"==":function(t,e){return lt(t)?t.equals(e):lt(e)?e.equals(t):t===e},"!=":function(t,e){return lt(t)?!t.equals(e):lt(e)?!e.equals(t):t!==e},">":function(t,e){return lt(t)?t.gt(e):lt(e)?e.lt(t):e<t},"<":function(t,e){return lt(t)?t.lt(e):lt(e)?e.gt(t):t<e},">=":function(t,e){return lt(t)?t.geq(e):lt(e)?e.leq(t):e<=t},"<=":function(t,e){return lt(t)?t.leq(e):lt(e)?e.geq(t):t<=e},contains:function(t,e){return!!t&&("function"==typeof t.indexOf&&-1<t.indexOf(e))},and:function(t,e){return yt(t)&&yt(e)},or:function(t,e){return yt(t)||yt(e)}};function gt(n,r){return d(this,void 0,void 0,function(){var e;return g(this,function(t){switch(t.label){case 0:return[4,function f(h,p){return d(this,void 0,void 0,function(){var e,n,r,i,o,s,u,a,c,l;return g(this,function(t){switch(t.label){case 0:E(p,"unable to parseExp: scope undefined"),e=ot,r=0,t.label=1;case 1:return r<e.length?(i=e[r],o=new RegExp("^("+I.source+")("+i.source+")("+I.source+")$"),(n=h.match(o))?[4,f(n[1],p)]:[3,4]):[3,5];case 2:return s=t.sent(),u=dt[n[2].trim()],[4,f(n[3],p)];case 3:return a=t.sent(),[2,u(s,a)];case 4:return r++,[3,1];case 5:return(n=h.match(it))?[4,mt(n[1],p)]:[3,8];case 6:return c=t.sent(),[4,mt(n[2],p)];case 7:return l=t.sent(),[2,w(+c,+l+1)];case 8:return[2,vt(h,p)]}})})}(n,r)];case 1:return[2,(e=t.sent())instanceof h?e.valueOf():e]}})})}function vt(e,n){return d(this,void 0,void 0,function(){return g(this,function(t){return e?"true"===(e=e.trim())?[2,!0]:"false"===e?[2,!1]:"nil"===e||"null"===e?[2,new pt]:"empty"===e?[2,new ft]:"blank"===e?[2,new ht]:isNaN(Number(e))?'"'!==e[0]&&"'"!==e[0]||e[0]!==l(e)?[2,n.get(e)]:[2,e.slice(1,-1)]:[2,Number(e)]:[2,null]})})}function mt(n,r){return d(this,void 0,void 0,function(){var e;return g(this,function(t){switch(t.label){case 0:return[4,vt(n,r)];case 1:return[2,(e=t.sent())instanceof h?e.valueOf():e]}})})}function yt(t){return!wt(t)}function wt(t){return!1===t||null==t}var bt=function(){function c(){}return c.create=function(u,a){return d(this,void 0,void 0,function(){var e,n,r,i,o,s;return g(this,function(t){switch(t.label){case 0:e=new c,et.lastIndex=0,t.label=1;case 1:return(n=et.exec(u))?(r=n[1],i=n[2],o=e,s=r,[4,mt(i,a)]):[3,3];case 2:return o[s]=t.sent(),[3,1];case 3:return[2,e]}})})},c}(),Tt=function(t){this.token=t},xt=function(s){function u(t,e,n){var r=s.call(this,t)||this;r.name=t.name;var i,o=u.impls[t.name];return E(o,"tag "+t.name+" not found"),r.impl=(i=o,Object.create(i)),r.impl.liquid=n,r.impl.parse&&r.impl.parse(t,e),r}return i(u,s),u.prototype.render=function(r){return d(this,void 0,void 0,function(){var e,n;return g(this,function(t){switch(t.label){case 0:return[4,bt.create(this.token.args,r)];case 1:return e=t.sent(),"function"!=typeof(n=this.impl).render?[2,""]:[4,n.render(r,e)];case 2:return[2,a(t.sent())]}})})},u.register=function(t,e){u.impls[t]=e},u.clear=function(){u.impls={}},u.impls={},u}(Tt),kt=function(){function i(t,e,n){var r=i.impls[t];if(!r&&n)throw new TypeError("undefined filter: "+t);this.name=t,this.impl=r||function(t){return t},this.args=e}return i.prototype.render=function(l,f){return d(this,void 0,void 0,function(){var e,n,r,i,o,s,u,a,c;return g(this,function(t){switch(t.label){case 0:e=[],n=0,r=this.args,t.label=1;case 1:return n<r.length?m(i=r[n])?(s=(o=e).push,u=[i[0]],[4,mt(i[1],f)]):[3,3]:[3,6];case 2:return s.apply(o,[u.concat([t.sent()])]),[3,5];case 3:return c=(a=e).push,[4,mt(i,f)];case 4:c.apply(a,[t.sent()]),t.label=5;case 5:return n++,[3,1];case 6:return[2,this.impl.apply(null,[l].concat(e))]}})})},i.register=function(t,e){i.impls[t]=e},i.clear=function(){i.impls={}},i.impls={},i}(),Et=function(){function t(t,e){this.handlers={},this.stopRequested=!1,this.tokens=t,this.parseToken=e}return t.prototype.on=function(t,e){return this.handlers[t]=e,this},t.prototype.trigger=function(t,e){var n=this.handlers[t];return"function"==typeof n&&(n(e),!0)},t.prototype.start=function(){var t;for(this.trigger("start");!this.stopRequested&&(t=this.tokens.shift());)if(!(this.trigger("token",t)||"tag"===t.type&&this.trigger("tag:"+t.name,t))){var e=this.parseToken(t,this.tokens);this.trigger("template",e)}return this.stopRequested||this.trigger("end"),this},t.prototype.stop=function(){return this.stopRequested=!0,this},t}(),St=function(){function r(t,e){this.filters=[];var n=r.tokenize(t);this.strictFilters=e,this.initial=n[0],this.parseFilters(n,1)}return r.prototype.parseFilters=function(t,e){for(var n=e;n<t.length;)if("|"===t[n]){for(var r=++n;n<t.length&&"|"!==t[n];)n++;this.parseFilter(t,r,n)}else n++},r.prototype.parseFilter=function(t,e,n){for(var r,i,o=t[e],s=[],u=e+1;u<n+1;u++)u===n||","===t[u]?((r||i)&&s.push(r?[r,i]:i),i=r=void 0):":"===t[u]?(r=i,i=void 0):void 0===i&&(i=t[u]);this.filters.push(new kt(o,s,this.strictFilters))},r.prototype.value=function(i){return d(this,void 0,void 0,function(){var e,n,r;return g(this,function(t){switch(t.label){case 0:return[4,gt(this.initial,i)];case 1:e=t.sent(),n=0,r=this.filters,t.label=2;case 2:return n<r.length?[4,r[n].render(e,i)]:[3,5];case 3:e=t.sent(),t.label=4;case 4:return n++,[3,2];case 5:return[2,e]}})})},r.tokenize=function(t){for(var e=[],n=0;n<t.length;){var r=t[n];if('"'===r||"'"===r){var i=n;for(n+=2;n<t.length&&t[n-1]!==r;++n);e.push(t.slice(i,n))}else if(/\s/.test(r))n++;else if(/[|,:]/.test(r))e.push(t[n++]);else{for(i=n++;n<t.length&&!/[|,:\s]/.test(t[n]);++n);e.push(t.slice(i,n))}}return e},r}(),qt=function(r){function t(t,e){var n=r.call(this,t)||this;return n.value=new St(t.value,e),n}return i(t,r),t.prototype.render=function(e){return d(this,void 0,void 0,function(){return g(this,function(t){switch(t.label){case 0:return[4,this.value.value(e)];case 1:return[2,a(t.sent())]}})})},t}(Tt),Ot=function(n){function t(t){var e=n.call(this,t)||this;return e.str=t.value,e}return i(t,n),t.prototype.render=function(){return d(this,void 0,void 0,function(){return g(this,function(t){return[2,this.str]})})},t}(Tt),Rt=function(){function t(t){this.liquid=t}return t.prototype.parse=function(t){for(var e,n=[];e=t.shift();)n.push(this.parseToken(e,t));return n},t.prototype.parseToken=function(e,t){try{return"tag"===e.type?new xt(e,t,this.liquid):"output"===e.type?new qt(e,this.liquid.options.strictFilters):new Ot(e)}catch(t){throw new n(t,e)}},t.prototype.parseStream=function(t){var n=this;return new Et(t,function(t,e){return n.parseToken(t,e)})},t}(),Mt=new RegExp("("+V.source+")\\s*=([^]*)"),Lt={parse:function(t){var e=t.args.match(Mt);E(e,"illegal token "+t.raw),this.key=e[1],this.value=e[2]},render:function(i){return d(this,void 0,void 0,function(){var e,n,r;return g(this,function(t){switch(t.label){case 0:return e=new P,n=e,r=this.key,[4,this.liquid.evalValue(this.value,i)];case 1:return n[r]=t.sent(),i.push(e),[2]}})})}},Ft=function(n){function t(t){var e=n.call(this)||this;return e.i=0,e.length=t,e}return i(t,n),t.prototype.next=function(){this.i++},t.prototype.index0=function(){return this.i},t.prototype.index=function(){return this.i+1},t.prototype.first=function(){return 0===this.i},t.prototype.last=function(){return this.i===this.length-1},t.prototype.rindex=function(){return this.length-this.i},t.prototype.rindex0=function(){return this.length-this.i-1},t.prototype.valueOf=function(){return JSON.stringify(this)},t}(h),Dt=new RegExp("^("+V.source+")\\s+in\\s+("+Z.source+")(?:\\s+"+tt.source+")*(?:\\s+(reversed))?(?:\\s+"+tt.source+")*$"),Pt={type:"block",parse:function(t,e){var n,r=this,i=Dt.exec(t.args);E(i,"illegal tag: "+t.raw),this.variable=i[1],this.collection=i[2],this.reversed=!!i[3],this.templates=[],this.elseTemplates=[];var o=this.liquid.parser.parseStream(e).on("start",function(){return n=r.templates}).on("tag:else",function(){return n=r.elseTemplates}).on("tag:endfor",function(){return o.stop()}).on("template",function(t){return n.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});o.start()},render:function(f,h){return d(this,void 0,void 0,function(){var e,n,r,i,o,s,u,a,c,l;return g(this,function(t){switch(t.label){case 0:return[4,gt(this.collection,f)];case 1:if(m(e=t.sent())||(p(e)&&0<e.length?e=[e]:y(e)&&(e=Object.keys(e).map(function(t){return[t,e[t]]}))),!m(e)||!e.length)return[2,this.liquid.renderer.renderTemplates(this.elseTemplates,f)];n=h.offset||0,r=void 0===h.limit?e.length:h.limit,e=e.slice(n,n+r),this.reversed&&e.reverse(),i={forloop:new Ft(e.length)},f.push(i),o="",s=0,u=e,t.label=2;case 2:if(!(s<u.length))return[3,8];a=u[s],i[this.variable]=a,t.label=3;case 3:return t.trys.push([3,5,,6]),c=o,[4,this.liquid.renderer.renderTemplates(this.templates,f)];case 4:return o=c+t.sent(),[3,6];case 5:if("RenderBreakError"!==(l=t.sent()).name)throw l;return o+=l.resolvedHTML,"break"===l.message?[3,8]:[3,6];case 6:i.forloop.next(),t.label=7;case 7:return s++,[3,2];case 8:return f.pop(),[2,o]}})})}},Ut=new RegExp("("+V.source+")"),jt={parse:function(t,e){var n=this,r=t.args.match(Ut);E(r,t.args+" not valid identifier"),this.variable=r[1],this.templates=[];var i=this.liquid.parser.parseStream(e);i.on("tag:endcapture",function(){return i.stop()}).on("template",function(t){return n.templates.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")}),i.start()},render:function(r){return d(this,void 0,void 0,function(){var e,n;return g(this,function(t){switch(t.label){case 0:return[4,this.liquid.renderer.renderTemplates(this.templates,r)];case 1:return e=t.sent(),(n=new D)[this.variable]=e,r.push(n),[2]}})})}},At={parse:function(t,e){var n=this;this.cond=t.args,this.cases=[],this.elseTemplates=[];var r=[],i=this.liquid.parser.parseStream(e).on("tag:when",function(t){n.cases.push({val:t.args,templates:r=[]})}).on("tag:else",function(){return r=n.elseTemplates}).on("tag:endcase",function(){return i.stop()}).on("template",function(t){return r.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});i.start()},render:function(o){return d(this,void 0,void 0,function(){var e,n,r,i;return g(this,function(t){switch(t.label){case 0:e=0,t.label=1;case 1:return e<this.cases.length?[4,gt((n=this.cases[e]).val,o)]:[3,5];case 2:return r=t.sent(),[4,gt(this.cond,o)];case 3:if(i=t.sent(),r===i)return[2,this.liquid.renderer.renderTemplates(n.templates,o)];t.label=4;case 4:return e++,[3,1];case 5:return[2,this.liquid.renderer.renderTemplates(this.elseTemplates,o)]}})})}},_t={parse:function(t,e){var n=this.liquid.parser.parseStream(e);n.on("token",function(t){"endcomment"===t.name&&n.stop()}).on("end",function(){throw new Error("tag "+t.raw+" not closed")}),n.start()}},Ht=/[^\s,]+/,Nt=new RegExp("with\\s+("+Z.source+")"),zt={parse:function(t){var e=Ht.exec(t.args);e&&(this.staticValue=e[0]),(e=Z.exec(t.args))&&(this.value=e[0]),(e=Nt.exec(t.args))&&(this.with=e[1])},render:function(c,l){return d(this,void 0,void 0,function(){var e,n,r,i,o,s,u,a;return g(this,function(t){switch(t.label){case 0:return c.opts.dynamicPartials?rt.exec(this.value)?(n=this.value.slice(1,-1),[4,this.liquid.parseAndRender(n,c.getAll(),c.opts)]):[3,2]:[3,5];case 1:return e=t.sent(),[3,4];case 2:return[4,mt(this.value,c)];case 3:e=t.sent(),t.label=4;case 4:return[3,6];case 5:e=this.staticValue,t.label=6;case 6:return E(e,"cannot include with empty filename"),r=c.blocks,i=c.blockMode,c.blocks={},c.blockMode=L.OUTPUT,this.with?(o=l,s=e,[4,mt(this.with,c)]):[3,8];case 7:o[s]=t.sent(),t.label=8;case 8:return[4,this.liquid.getTemplate(e,c.opts)];case 9:return u=t.sent(),c.push(l),[4,this.liquid.renderer.renderTemplates(u,c)];case 10:return a=t.sent(),c.pop(l),c.blocks=r,c.blockMode=i,[2,a]}})})}},Ct={parse:function(t){var e=t.args.match(V);E(e,"illegal identifier "+t.args),this.variable=e[0]},render:function(t){var e=t.findContextFor(this.variable,function(t){return!(t instanceof D||t instanceof P)});return e||(e=new j,t.unshift(e)),"number"!=typeof e[this.variable]&&(e[this.variable]=0),--e[this.variable]}},Yt=new RegExp("^(?:("+Z.source+")\\s*:\\s*)?(.*)$"),$t=new RegExp(Z.source,"g"),It={parse:function(t){var e=Yt.exec(t.args);E(e,"illegal tag: "+t.raw),this.group=e[1]||"";var n=e[2];for(this.candidates=[];e=$t.exec(n);)this.candidates.push(e[0]);E(this.candidates.length,"empty candidates: "+t.raw)},render:function(s){return d(this,void 0,void 0,function(){var e,n,r,i,o;return g(this,function(t){switch(t.label){case 0:return[4,mt(this.group,s)];case 1:return e=t.sent(),n="cycle:"+e+":"+this.candidates.join(","),r=s.groups,void 0===(i=r[n])&&(i=r[n]=0),o=this.candidates[i],i=(i+1)%this.candidates.length,r[n]=i,[2,mt(o,s)]}})})}},Bt={parse:function(t,e){var n,r=this;this.branches=[],this.elseTemplates=[];var i=this.liquid.parser.parseStream(e).on("start",function(){return r.branches.push({cond:t.args,templates:n=[]})}).on("tag:elsif",function(t){r.branches.push({cond:t.args,templates:n=[]})}).on("tag:else",function(){return n=r.elseTemplates}).on("tag:endif",function(){return i.stop()}).on("template",function(t){return n.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});i.start()},render:function(i){return d(this,void 0,void 0,function(){var e,n,r;return g(this,function(t){switch(t.label){case 0:e=0,n=this.branches,t.label=1;case 1:return e<n.length?[4,gt((r=n[e]).cond,i)]:[3,4];case 2:if(yt(t.sent()))return[2,this.liquid.renderer.renderTemplates(r.templates,i)];t.label=3;case 3:return e++,[3,1];case 4:return[2,this.liquid.renderer.renderTemplates(this.elseTemplates,i)]}})})}},Vt={parse:function(t){var e=t.args.match(V);E(e,"illegal identifier "+t.args),this.variable=e[0]},render:function(t){var e=t.findContextFor(this.variable,function(t){return!(t instanceof D||t instanceof P)});e||(e=new U,t.unshift(e)),"number"!=typeof e[this.variable]&&(e[this.variable]=0);var n=e[this.variable];return e[this.variable]++,n}},Gt=/\S+/,Wt={parse:function(t,e){var n=Gt.exec(t.args);n&&(this.staticLayout=n[0]),(n=Z.exec(t.args))&&(this.layout=n[0]),this.tpls=this.liquid.parser.parse(e)},render:function(s,u){return d(this,void 0,void 0,function(){var e,n,r,i,o;return g(this,function(t){switch(t.label){case 0:return s.opts.dynamicPartials?[4,mt(this.layout,s)]:[3,2];case 1:return n=t.sent(),[3,3];case 2:n=this.staticLayout,t.label=3;case 3:return E(e=n,"cannot apply layout with empty filename"),s.blockMode=L.STORE,[4,this.liquid.renderer.renderTemplates(this.tpls,s)];case 4:return r=t.sent(),void 0===s.blocks[""]&&(s.blocks[""]=r),[4,this.liquid.getTemplate(e,s.opts)];case 5:return i=t.sent(),s.push(u),s.blockMode=L.OUTPUT,[4,this.liquid.renderer.renderTemplates(i,s)];case 6:return o=t.sent(),s.pop(u),[2,o]}})})}},Jt={parse:function(t,e){var n=this,r=/\w+/.exec(t.args);this.block=r?r[0]:"",this.tpls=[];var i=this.liquid.parser.parseStream(e).on("tag:endblock",function(){return i.stop()}).on("template",function(t){return n.tpls.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});i.start()},render:function(i){return d(this,void 0,void 0,function(){var e,n,r;return g(this,function(t){switch(t.label){case 0:return void 0===(e=i.blocks[this.block])?[3,1]:(r=e,[3,3]);case 1:return[4,this.liquid.renderer.renderTemplates(this.tpls,i)];case 2:r=t.sent(),t.label=3;case 3:return n=r,i.blockMode===L.STORE?(i.blocks[this.block]=n,[2,""]):[2,n]}})})}},Xt={parse:function(t,e){var n=this;this.tokens=[];var r=this.liquid.parser.parseStream(e);r.on("token",function(t){"endraw"===t.name?r.stop():n.tokens.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")}),r.start()},render:function(){return this.tokens.map(function(t){return t.raw}).join("")}},Kt=function(r){function t(t,e){var n=r.call(this,t)||this;return n.length=t,n.cols=e,n}return i(t,r),t.prototype.row=function(){return Math.floor(this.i/this.cols)+1},t.prototype.col0=function(){return this.i%this.cols},t.prototype.col=function(){return this.col0()+1},t.prototype.col_first=function(){return 0===this.col0()},t.prototype.col_last=function(){return this.col()===this.cols},t}(Ft),Qt=new RegExp("^("+V.source+")\\s+in\\s+("+Z.source+")(?:\\s+"+tt.source+")*$"),Zt={assign:Lt,for:Pt,capture:jt,case:At,comment:_t,include:zt,decrement:Ct,increment:Vt,cycle:It,if:Bt,layout:Wt,block:Jt,raw:Xt,tablerow:{parse:function(t,e){var n,r=this,i=Qt.exec(t.args);E(i,"illegal tag: "+t.raw),this.variable=i[1],this.collection=i[2],this.templates=[];var o=this.liquid.parser.parseStream(e).on("start",function(){return n=r.templates}).on("tag:endtablerow",function(){return o.stop()}).on("template",function(t){return n.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});o.start()},render:function(l,f){return d(this,void 0,void 0,function(){var e,n,r,i,o,s,u,a,c;return g(this,function(t){switch(t.label){case 0:return[4,gt(this.collection,l)];case 1:e=t.sent()||[],n=f.offset||0,r=void 0===f.limit?e.length:f.limit,e=e.slice(n,n+r),i=f.cols||e.length,o=new Kt(e.length,i),s={tablerowloop:o},l.push(s),u="",a=0,t.label=2;case 2:return a<e.length?(s[this.variable]=e[a],0===o.col0()&&(1!==o.row()&&(u+="</tr>"),u+='<tr class="row'+o.row()+'">'),u+='<td class="col'+o.col()+'">',c=u,[4,this.liquid.renderer.renderTemplates(this.templates,l)]):[3,5];case 3:u=c+t.sent(),u+="</td>",t.label=4;case 4:return a++,o.next(),[3,2];case 5:return e.length&&(u+="</tr>"),l.pop(s),[2,u]}})})}},unless:{parse:function(t,e){var n,r=this;this.templates=[],this.elseTemplates=[];var i=this.liquid.parser.parseStream(e).on("start",function(){n=r.templates,r.cond=t.args}).on("tag:else",function(){return n=r.elseTemplates}).on("tag:endunless",function(){return i.stop()}).on("template",function(t){return n.push(t)}).on("end",function(){throw new Error("tag "+t.raw+" not closed")});i.start()},render:function(e){return d(this,void 0,void 0,function(){return g(this,function(t){switch(t.label){case 0:return[4,gt(this.cond,e)];case 1:return[2,wt(t.sent())?this.liquid.renderer.renderTemplates(this.templates,e):this.liquid.renderer.renderTemplates(this.elseTemplates,e)]}})})}},break:{render:function(){return d(this,void 0,void 0,function(){return g(this,function(t){throw new x("break")})})}},continue:{render:function(){return d(this,void 0,void 0,function(){return g(this,function(t){throw new x("continue")})})}}},te={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&#34;","'":"&#39;"},ee={"&amp;":"&","&lt;":"<","&gt;":">","&#34;":'"',"&#39;":"'"};function ne(t){return String(t).replace(/&|<|>|"|'/g,function(t){return te[t]})}var re={escape:ne,escape_once:function(t){return ne(String(t).replace(/&(amp|lt|gt|#34|#39);/g,function(t){return ee[t]}))},newline_to_br:function(t){return t.replace(/\n/g,"<br />")},strip_html:function(t){return t.replace(/<script.*?<\/script>|<!--.*?-->|<style.*?<\/style>|<.*?>/g,"")}},ie={append:function(t,e){return t+e},prepend:function(t,e){return e+t},capitalize:function(t){return String(t).charAt(0).toUpperCase()+t.slice(1)},lstrip:function(t){return String(t).replace(/^\s+/,"")},downcase:function(t){return t.toLowerCase()},upcase:function(t){return String(t).toUpperCase()},remove:function(t,e){return t.split(e).join("")},remove_first:function(t,e){return t.replace(e,"")},replace:function(t,e,n){return String(t).split(e).join(n)},replace_first:function(t,e,n){return String(t).replace(e,n)},rstrip:function(t){return String(t).replace(/\s+$/,"")},split:function(t,e){return String(t).split(e)},strip:function(t){return String(t).trim()},strip_newlines:function(t){return String(t).replace(/\n/g,"")},truncate:function(t,e,n){return void 0===e&&(e=50),void 0===n&&(n="..."),(t=String(t)).length<=e?t:t.substr(0,e-n.length)+n},truncatewords:function(t,e,n){void 0===e&&(e=15),void 0===n&&(n="...");var r=t.split(/\s+/),i=r.slice(0,e).join(" ");return r.length>=e&&(i+=n),i}},oe={abs:function(t){return Math.abs(t)},ceil:function(t){return Math.ceil(t)},divided_by:function(t,e){return t/e},floor:function(t){return Math.floor(t)},minus:function(t,e){return t-e},modulo:function(t,e){return t%e},round:function(t,e){void 0===e&&(e=0);var n=Math.pow(10,e);return Math.round(t*n)/n},plus:function(t,e){return Number(t)+Number(e)},times:function(t,e){return t*e}},se={url_decode:function(t){return t.split("+").map(decodeURIComponent).join(" ")},url_encode:function(t){return t.split(" ").map(encodeURIComponent).join("+")}},ue={join:function(t,e){return t.join(void 0===e?" ":e)},last:function(t){return l(t)},first:function(t){return t[0]},map:function(t,e){return t.map(function(t){return t[e]})},reverse:function(t){return t.reverse()},sort:function(t,e){return t.sort(e)},size:function(t){return t.length},concat:function(t,e){return Array.prototype.concat.call(t,e)},slice:function(t,e,n){return void 0===n&&(n=1),t.slice(e,e+n)},uniq:function(t){var e={};return(t||[]).filter(function(t){return!e.hasOwnProperty(String(t))&&(e[String(t)]=!0)})}},ae=["January","February","March","April","May","June","July","August","September","October","November","December"],ce=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],le=ae.map(pe),fe=ce.map(pe),he={1:"st",2:"nd",3:"rd",default:"th"};function pe(t){return t.slice(0,3)}var de={daysInMonth:function(t){return[31,de.isLeapYear(t)?29:28,31,30,31,30,31,31,30,31,30,31]},getDayOfYear:function(t){for(var e=0,n=0;n<t.getMonth();++n)e+=de.daysInMonth(t)[n];return e+t.getDate()},getWeekOfYear:function(t,e){var n=this.getDayOfYear(t)+(e-t.getDay()),r=7-new Date(t.getFullYear(),0,1).getDay()+e;return f(String(Math.floor((n-r)/7)+1),2,"0")},isLeapYear:function(t){var e=t.getFullYear();return!(0!=(3&e)||!(e%100||e%400==0&&e))},getSuffix:function(t){var e=t.getDate().toString(),n=parseInt(e.slice(-1));return he[n]||he.default},century:function(t){return parseInt(t.getFullYear().toString().substring(0,2),10)}},ge={a:function(t){return fe[t.getDay()]},A:function(t){return ce[t.getDay()]},b:function(t){return le[t.getMonth()]},B:function(t){return ae[t.getMonth()]},c:function(t){return t.toLocaleString()},C:function(t){return de.century(t)},d:function(t){return f(t.getDate(),2,"0")},e:function(t){return f(t.getDate(),2)},H:function(t){return f(t.getHours(),2,"0")},I:function(t){return f(String(t.getHours()%12||12),2,"0")},j:function(t){return f(de.getDayOfYear(t),3,"0")},k:function(t){return f(t.getHours(),2)},l:function(t){return f(String(t.getHours()%12||12),2)},L:function(t){return f(t.getMilliseconds(),3,"0")},m:function(t){return f(t.getMonth()+1,2,"0")},M:function(t){return f(t.getMinutes(),2,"0")},p:function(t){return t.getHours()<12?"AM":"PM"},P:function(t){return t.getHours()<12?"am":"pm"},q:function(t){return de.getSuffix(t)},s:function(t){return Math.round(t.valueOf()/1e3)},S:function(t){return f(t.getSeconds(),2,"0")},u:function(t){return t.getDay()||7},U:function(t){return de.getWeekOfYear(t,0)},w:function(t){return t.getDay()},W:function(t){return de.getWeekOfYear(t,1)},x:function(t){return t.toLocaleDateString()},X:function(t){return t.toLocaleTimeString()},y:function(t){return t.getFullYear().toString().substring(2,4)},Y:function(t){return t.getFullYear()},z:function(t){var e=t.getTimezoneOffset()/60*100;return(0<e?"-":"+")+f(String(Math.abs(e)),4,"0")},"%":function(){return"%"}};ge.h=ge.b,ge.N=ge.L;var ve=v({},re,ie,oe,se,{date:function(t,e){var n,r=t;return"now"===t?r=new Date:p(t)&&(r=new Date(t)),(n=r)instanceof Date&&!isNaN(n.getTime())?function(t,e){for(var n="",r=e;;){var i=/%./g,o=i.exec(r);if(!o)return n+r;n+=r.slice(0,i.lastIndex-2),r=r.slice(i.lastIndex);var s=o[0].charAt(1),u=ge[s];n+=u?u(t):"%"+s}}(r,e):t}},{default:function(t,e){return yt(t)?t:e}},ue);return function(){function e(t){void 0===t&&(t={});var n=this;this.cache={},this.options=M(R(t)),this.parser=new Rt(this),this.renderer=new ct,this.tokenizer=new at(this.options),c(Zt,function(t,e){return n.registerTag(e,t)}),c(ve,function(t,e){return n.registerFilter(e,t)})}return e.prototype.parse=function(t,e){var n=this.tokenizer.tokenize(t,e);return this.parser.parse(n)},e.prototype.render=function(t,e,n){var r=v({},this.options,R(n)),i=new F(e,r);return this.renderer.renderTemplates(t,i)},e.prototype.parseAndRender=function(n,r,i){return d(this,void 0,void 0,function(){var e;return g(this,function(t){switch(t.label){case 0:return[4,this.parse(n)];case 1:return e=t.sent(),[2,this.render(e,r,i)]}})})},e.prototype.getTemplate=function(f,h){return d(this,void 0,void 0,function(){var e,n,r,i,o,s,u,a,c,l=this;return g(this,function(t){switch(t.label){case 0:e=R(h),n=e.root?e.root.concat(this.options.root):this.options.root,r=n.map(function(t){return _.resolve(t,f,l.options.extname)}),i=0,o=r,t.label=1;case 1:return i<o.length?(s=o[i],[4,_.exists(s)]):[3,5];case 2:return t.sent()?this.options.cache&&this.cache[s]?[2,this.cache[s]]:(a=this.parse,[4,_.readFile(s)]):[3,4];case 3:return u=a.apply(this,[t.sent(),s]),this.options.cache&&(this.cache[s]=u),[2,u];case 4:return i++,[3,1];case 5:throw(c=new Error("ENOENT")).message='ENOENT: Failed to lookup "'+f+'" in "'+n+'"',c.code="ENOENT",c}})})},e.prototype.renderFile=function(r,i,o){return d(this,void 0,void 0,function(){var e,n;return g(this,function(t){switch(t.label){case 0:return e=R(o),[4,this.getTemplate(r,e)];case 1:return n=t.sent(),[2,this.render(n,i,o)]}})})},e.prototype.evalValue=function(t,e){return new St(t,this.options.strictFilters).value(e)},e.prototype.registerFilter=function(t,e){return kt.register(t,e)},e.prototype.registerTag=function(t,e){return xt.register(t,e)},e.prototype.plugin=function(t){return t.call(this,e)},e.prototype.express=function(){var i=this;return function(t,e,n){var r={root:this.root};i.renderFile(t,e,r).then(function(t){return n(null,t)},n)}},(e.default=e).isTruthy=yt,e.isFalsy=wt,e.evalExp=gt,e.evalValue=mt,e.Types=A,e}()});
//# sourceMappingURL=liquid.min.js.map
import Scope from '../scope/scope';
export declare function parseExp(exp: string, scope: Scope): any;
export declare function evalExp(str: string, scope: Scope): any;
export declare function evalValue(str: string | undefined, scope: Scope): any;
export declare function parseExp(exp: string, scope: Scope): Promise<any>;
export declare function evalExp(str: string, scope: Scope): Promise<any>;
export declare function evalValue(str: string | undefined, scope: Scope): Promise<any>;
export declare function isTruthy(val: any): boolean;
export declare function isFalsy(val: any): boolean;

@@ -0,9 +1,5 @@

import { Drop } from '../drop/drop';
import { NormalizedFullOptions } from '../liquid-options';
import BlockMode from './block-mode';
export declare type Context = {
[key: string]: any;
liquid_method_missing?: (key: string) => any;
to_liquid?: () => any;
toLiquid?: () => any;
};
import { Context } from './context';
export default class Scope {

@@ -19,10 +15,13 @@ opts: NormalizedFullOptions;

getAll(): Context;
get(path: string): any;
set(path: string, v: any): void;
get(path: string): Promise<Context>;
set(path: string, v: any): Promise<void>;
unshift(ctx: object): number;
push(ctx: object): number;
pop(ctx?: object): object | undefined;
findContextFor(key: string, filter?: ((conttext: object) => boolean)): Context | null;
findContextFor(key: string, filter?: ((conttext: object) => boolean)): {
[key: string]: any;
toLiquid?: (() => any) | undefined;
} | Drop | null;
private readProperty;
propertyAccessSeq(str: string): string[];
propertyAccessSeq(str: string): Promise<string[]>;
}

@@ -10,5 +10,5 @@ import Scope from '../../scope/scope';

constructor(name: string, args: FilterArgs, strictFilters: boolean);
render(value: any, scope: Scope): any;
render(value: any, scope: Scope): Promise<any>;
static register(name: string, filter: FilterImpl): void;
static clear(): void;
}

@@ -10,3 +10,3 @@ import Scope from '../../scope/scope';

[key: string]: any;
constructor(markup: string, scope: Scope);
static create(markup: string, scope: Scope): Promise<Hash>;
}

@@ -13,4 +13,4 @@ import { Filter } from './filter/filter';

private parseFilter;
value(scope: Scope): any;
value(scope: Scope): Promise<any>;
static tokenize(str: string): Array<'|' | ',' | ':' | string>;
}
{
"name": "liquidjs",
"version": "7.5.1",
"version": "8.0.0",
"description": "Liquid template engine by pure JavaScript: compatible to shopify, easy to extend.",

@@ -5,0 +5,0 @@ "main": "dist/liquid.common.js",

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc