From b1a67eb63239724280bee7686513cd785f325d66 Mon Sep 17 00:00:00 2001 From: Jean-Patrick Guerrero Date: Thu, 7 Mar 2019 13:43:47 +0100 Subject: [PATCH] Add examples in doc --- API.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/API.md b/API.md index 9a0f74b..e03a0e2 100644 --- a/API.md +++ b/API.md @@ -70,10 +70,15 @@ Returns a map of recipe filters, indexed by name. Search filters are used to perform specific searches inside the search field. They can be used like so: `+=,,<...>` +Examples: + +- `+groups=cracky,crumbly`: search for groups `cracky` and `crumbly` in all items. +- `sand+groups=falling_node`: search for group `falling_node` for items which contain `sand` in their names. + Notes: - If `optional name` is omitted, the search filter will apply to all items, without pre-filtering. - Filters can be combined. -- The `+groups=` filter is currently implemented by default. +- The `groups` filter is currently implemented by default. #### `craftguide.add_search_filter(name, function(item, values))`