diff options
Diffstat (limited to 'public/javascripts/autocomplete.js')
-rw-r--r-- | public/javascripts/autocomplete.js | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/public/javascripts/autocomplete.js b/public/javascripts/autocomplete.js new file mode 100644 index 0000000..7a56e16 --- /dev/null +++ b/public/javascripts/autocomplete.js @@ -0,0 +1,15 @@ +const autocomplete = {} +const self = autocomplete + +self._nodes = { + input: document.querySelector('input[type="search"]'), + autocomplete: document.querySelector('.autocomplete') +} + +self._textUpdate = function () { + self._nodes.autocomplete +} + +self._nodes.input.addEventListener('input', self.hide) + +module.exports = autocomplete |