mirror of
https://github.com/harttle/liquidjs.git
synced 2026-09-18 14:00:39 -07:00
feat: add unregisterFilter method (#946)
* feat: add unregisterFilter method * docs: show how to re-register built-in filters --------- Co-authored-by: Yacov <yacov@noemail>
This commit is contained in:
@@ -101,6 +101,9 @@ export class Liquid {
|
||||
public registerFilter (name: string, filter: FilterImplOptions) {
|
||||
this.filters[name] = filter
|
||||
}
|
||||
public unregisterFilter (name: string) {
|
||||
delete this.filters[name]
|
||||
}
|
||||
public registerTag (name: string, tag: TagClass | TagImplOptions) {
|
||||
this.tags[name] = isFunction(tag) ? tag : createTagClass(tag)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user