Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Split Search Javascript file into a library and a separate widget #174

Open
cjbrooks12 opened this issue Sep 26, 2018 · 0 comments
Open
Labels
good first issue plugins Project Type: Plugins, Language extensions refactor Task Type: Refactoring, code cleanup, etc.
Projects

Comments

@cjbrooks12
Copy link
Contributor

By splitting the Search Javascript file into a library component and a widget component, it will be easier to implement into themes.

The library encapsulates all the functionality of fetching the local site's JSON indices and booting up lunr.js. It provides a simple public API for loading and querying data, and returns a list of results that can be used in any front-end framework.

The widget component should include the library component, and provide a fully-encapsulated search solution. By attaching the widget to any existing form element, when the form is submitted it will load the results into a dropdown and provide basic, default styling for it. This widget will not be designed to be customized for the theme. Rather, if custom styling is desired, then the theme should write its own search component using the search library. It shouldn't be too difficult.

In addition, I would like to re-write this component using Kotlin/JS. The widget might be re-written in VueJS, rather than JQuery or vanilla JS.

@cjbrooks12 cjbrooks12 added refactor Task Type: Refactoring, code cleanup, etc. plugins Project Type: Plugins, Language extensions labels Sep 26, 2018
@cjbrooks12 cjbrooks12 added this to Triage in Backlog via automation Sep 26, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue plugins Project Type: Plugins, Language extensions refactor Task Type: Refactoring, code cleanup, etc.
Projects
Backlog
  
Triage
Development

No branches or pull requests

1 participant