diff options
author | Samy Pesse <samypesse@gmail.com> | 2016-09-29 16:03:16 +0200 |
---|---|---|
committer | Samy Pesse <samypesse@gmail.com> | 2016-09-29 16:03:16 +0200 |
commit | 7f283791544195fa70c51003db9be3f029c014ef (patch) | |
tree | 4a5ac11ed2a3f1b6e6e0a8d3e7bedd641c0f186f /packages/gitbook-plugin-search/src/index.js | |
parent | 6f98ee18468e88af01a066eb6e203e4d6ef0a52c (diff) | |
download | gitbook-7f283791544195fa70c51003db9be3f029c014ef.zip gitbook-7f283791544195fa70c51003db9be3f029c014ef.tar.gz gitbook-7f283791544195fa70c51003db9be3f029c014ef.tar.bz2 |
Fix dist command
Diffstat (limited to 'packages/gitbook-plugin-search/src/index.js')
-rw-r--r-- | packages/gitbook-plugin-search/src/index.js | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/packages/gitbook-plugin-search/src/index.js b/packages/gitbook-plugin-search/src/index.js index 94a5d35..c3b0253 100644 --- a/packages/gitbook-plugin-search/src/index.js +++ b/packages/gitbook-plugin-search/src/index.js @@ -3,11 +3,15 @@ const GitBook = require('gitbook-core'); const SearchInput = require('./components/Input'); const SearchResults = require('./components/Results'); const reducers = require('./reducers'); +const search = require('./actions/search'); -module.exports = GitBook.createPlugin( - (dispatch, state) => { +module.exports = GitBook.createPlugin({ + init: (dispatch, getState) => { dispatch(GitBook.registerComponent(SearchInput, { role: 'search:input' })); dispatch(GitBook.registerComponent(SearchResults, { role: 'search:results' })); }, - reducers -); + reduce: reducers, + actions: { + search + } +}); |