Giter Site home page Giter Site logo

advanced-typeahead's Introduction

#Advanced Type Ahead

User Story:

User starts to type in a word and a drop down menu showing entities broken out by type appears. The entities are selectable.

Acceptance:

Produces a deduped list with a variety of entity types.

Usage:

Currently the project is in two parts: an HTML/CSS/JS frontend (in the html folder) and a Python Django backend (in the backend folder).

HTML/CSS/JS Frontend

Place this on a web server and visit index.html. It also works running it from your filesystem. Needed libraries not loaded from a cdn are included in html/scripts.

Installing the Application

The application consists of a backend server that makes calls to OCLC web services, and a stand alone web page that offers a text input for searching and displays results.

Backend Requirements:

Install the dependencies:

git clone https://github.com/OCLC-Developer-Network/oclc-auth-python.git
cd oclc-auth-python
sudo python setup.py install
cd ..
sudo pip install Django
sudo pip install djangorestframework
sudo pip install markdown
sudo pip install requests
sudo pip install rdflib
sudo pip install django-cors-headers

Install the application:

git clone https://github.com/oclc-developer-house/advanced-typeahead.git

Configure the OCLC Discovery API Authorization parameters:

You'll need to rename backend/backend/settings/authentication_template.py to backend/backend/settings/authentication.py and fill in the blanks with your OCLC WSkey details.

Run the Django Server:

Launch the Django dev server by running backend/devstart.sh. It's set to listen on localhost:8000.

Note that default Django settings from spinning up a basic project are used, and the secret key is currently included in settings/base.py, so under no circumstances should this be used in a production environment as-is.

Open the web page in the browser

With the backend running in the Django server, open the file html/index.html in your browser to run the example.

advanced-typeahead's People

Contributors

campbelg avatar jthomale avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

kayiwa danood

advanced-typeahead's Issues

Add loading bar to results list

Add small loading bar or animation to the results list view when a new search has been submitted before the results have loaded.

Sort results list

Sort the results list that comes back in the UI after you search.

Add more error checking

If the web services powering the JavaScript app aren't available for some reason, the app doesn't fail very gracefully. I'm not 100% confident that the RDF parsing is solid and won't fail under certain circumstances, so more error checking there wouldn't hurt either.

Maintain page state.

When you go back to the page, maintain page state so it doesn't have to reload the search.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.