Git Product home page Git Product logo

material-ui-youtube-autocomplete's Introduction

material-ui-youtube-autocomplete

A React.js Autcomplete complete component inspired by Material-UI.

Demo

See this compenent in action

Installation

npm install --save material-ui-youtube-autocomplete

Features

  • Material-UI stylized search input
  • Auto-suggest drop-down as user types (suggested results come from Youtube)
  • Retrieve collection of video search results from Youtube

Usage

import YoutubeAutcomplete from 'material-ui-youtube-autocomplete';

<YoutubeAutocomplete
  apiKey={string}        // you must get an API key from google if you want video search results returned
  maxResults={string}    // defaults -> 50. Number of video search results you want
  placeHolder={string}   // defaults -> "Search Youtube"
  callback={function}    // callback to execute when search results are retrieved
/>

Example

import YoutubeAutocomplete from 'material-ui-youtube-autocomplete';

class Example extends React.Component {
  render() {
    return (
      <YouTubeAutocomplete
        apiKey="YOUR-API-KEY-THAT-YOUR-REGISTERED-WITH-GOOGLE"
        placeHolder="Search Youtube"
        maxResults="20"
        callback={this._onSearchResultsFound}
      />
    );
  }

  _onSearchResultsFound(results) {
    // Results is an array of retreived search results from Youtube.
    // Do what you want with the results here.
  }
}

License

MIT

Course

Are you looking to build a professional app for the Web using React & Redux?

Check out my course "How to Write a Single Page Application".

www.singlepageapplication.com

material-ui-youtube-autocomplete's People

Contributors

hackingbeauty avatar

Stargazers

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

Watchers

 avatar  avatar  avatar

material-ui-youtube-autocomplete's Issues

EPEERINVALID error with npm install

error

npm ERR! Darwin 15.5.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "material-ui-youtube-autocomplete" "--save"
npm ERR! node v4.4.5
npm ERR! npm  v2.15.5
npm ERR! code EPEERINVALID

npm ERR! peerinvalid The package [email protected] does not satisfy its siblings' peerDependencies requirements!
npm ERR! peerinvalid Peer [email protected] wants react@>=0.14.0
npm ERR! peerinvalid Peer [email protected] wants react@^15.1.0
npm ERR! peerinvalid Peer [email protected] wants react@^0.14.7 || ^15.0.0-0
npm ERR! peerinvalid Peer [email protected] wants [email protected] || 0.14.x || 15.x.x
npm ERR! peerinvalid Peer [email protected] wants react@>= 0.14.0
npm ERR! peerinvalid Peer [email protected] wants [email protected] - 15
npm ERR! peerinvalid Peer [email protected] wants react@>= 0.13.0
npm ERR! peerinvalid Peer [email protected] wants react@>=0.12.0
npm ERR! peerinvalid Peer [email protected] wants react@^0.14.0 || ^15.0.0-0
npm ERR! peerinvalid Peer [email protected] wants react@^0.14.0 || ^15.0.0
npm ERR! peerinvalid Peer [email protected] wants react@^0.14.0 || ^15.0.0
npm ERR! peerinvalid Peer [email protected] wants react@^0.14 || ^15.0.0-rc || ^15.0
npm ERR! peerinvalid Peer [email protected] wants react@>=0.14.0
npm ERR! peerinvalid Peer [email protected] wants react@>=0.14.1
npm ERR! peerinvalid Peer [email protected] wants react@^0.14.0 || ^15.0.0
npm ERR! peerinvalid Peer [email protected] wants react@^0.14.0 || ^15.0.0
npm ERR! peerinvalid Peer [email protected] wants react@^0.14.0
npm ERR! peerinvalid Peer [email protected] wants react@^15.0.0
npm ERR! peerinvalid Peer [email protected] wants react@^15.0.0

I'm using "react": "^15.1.0" thank

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.