diff options
author | Marcia Ramos <virtua.creative@gmail.com> | 2018-03-06 00:00:37 +0300 |
---|---|---|
committer | Marcia Ramos <virtua.creative@gmail.com> | 2018-03-06 00:00:37 +0300 |
commit | 9099406097e281378a74e3d70c1ae890e1a1610d (patch) | |
tree | 1db8e9809a7ef93e991a8a9e560aa0a474c64798 /layouts | |
parent | e405591c6d795b8f990b550355b0691d345b225e (diff) |
add search result stats
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/instantsearch.html | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/layouts/instantsearch.html b/layouts/instantsearch.html index 966317db..1b90d22a 100644 --- a/layouts/instantsearch.html +++ b/layouts/instantsearch.html @@ -56,6 +56,18 @@ }) ); + search.addWidget( + instantsearch.widgets.stats({ + container: '#stats', + templates: { + body: function(data) { + return '<div class="stats"><em>You have ' + data.nbHits + ' results, fetched in ' + + data.processingTimeMS +'ms.</em></div>' + } + } + }) + ); + search.start(); </script> </body> |