Subversion Repositories Integrator Subversion

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
1 espaco 1
[![build status](https://secure.travis-ci.org/twitter/typeahead.js.png?branch=master)](http://travis-ci.org/twitter/typeahead.js)
2
[![Built with Grunt](https://cdn.gruntjs.com/builtwith.png)](http://gruntjs.com/)
3
 
4
 
5
[typeahead.js][gh-page]
6
=======================
7
 
8
Inspired by [twitter.com]'s autocomplete search functionality, typeahead.js is
9
a flexible JavaScript library that provides a strong foundation for building
10
robust typeaheads.
11
 
12
The typeahead.js library consists of 2 components: the suggestion engine,
13
[Bloodhound], and the UI view, [Typeahead].
14
The suggestion engine is responsible for computing suggestions for a given
15
query. The UI view is responsible for rendering suggestions and handling DOM
16
interactions. Both components can be used separately, but when used together,
17
they can provide a rich typeahead experience.
18
 
19
<!-- section links -->
20
 
21
[gh-page]: http://twitter.github.io/typeahead.js/
22
[twitter.com]: https://twitter.com
23
[Bloodhound]: https://github.com/twitter/typeahead.js/blob/master/doc/bloodhound.md
24
[Typeahead]: https://github.com/twitter/typeahead.js/blob/master/doc/jquery_typeahead.md
25
 
26
Getting Started
27
---------------
28
 
29
How you acquire typeahead.js is up to you.
30
 
31
Preferred method:
32
* Install with [Bower]: `$ bower install typeahead.js`
33
 
34
Other methods:
35
* [Download zipball of latest release][zipball].
36
* Download the latest dist files individually:
37
  * *[bloodhound.js]* (standalone suggestion engine)
38
  * *[typeahead.jquery.js]* (standalone UI view)
39
  * *[typeahead.bundle.js]* (*bloodhound.js* + *typeahead.jquery.js*)
40
  * *[typeahead.bundle.min.js]*
41
 
42
**Note:** both *bloodhound.js* and *typeahead.jquery.js* have a dependency on
43
[jQuery] 1.9+.
44
 
45
<!-- section links -->
46
 
47
[Bower]: http://bower.io/
48
[zipball]: http://twitter.github.com/typeahead.js/releases/latest/typeahead.js.zip
49
[bloodhound.js]: http://twitter.github.com/typeahead.js/releases/latest/bloodhound.js
50
[typeahead.jquery.js]: http://twitter.github.com/typeahead.js/releases/latest/typeahead.jquery.js
51
[typeahead.bundle.js]: http://twitter.github.com/typeahead.js/releases/latest/typeahead.bundle.js
52
[typeahead.bundle.min.js]: http://twitter.github.com/typeahead.js/releases/latest/typeahead.bundle.min.js
53
[jQuery]: http://jquery.com/
54
 
55
Documentation
56
-------------
57
 
58
* [Typeahead Docs]
59
* [Bloodhound Docs]
60
 
61
[Typeahead Docs]: https://github.com/twitter/typeahead.js/blob/master/doc/jquery_typeahead.md
62
[Bloodhound Docs]: https://github.com/twitter/typeahead.js/blob/master/doc/bloodhound.md
63
 
64
Examples
65
--------
66
 
67
For some working examples of typeahead.js, visit the [examples page].
68
 
69
<!-- section links -->
70
 
71
[examples page]: http://twitter.github.io/typeahead.js/examples
72
 
73
Browser Support
74
---------------
75
 
76
* Chrome
77
* Firefox 3.5+
78
* Safari 4+
79
* Internet Explorer 7+
80
* Opera 11+
81
 
82
**NOTE:** typeahead.js is not tested on mobile browers.
83
 
84
Customer Support
85
----------------
86
 
87
For general questions about typeahead.js, tweet at [@typeahead].
88
 
89
For technical questions, you should post a question on [Stack Overflow] and tag
90
it with [typeahead.js][so tag].
91
 
92
<!-- section links -->
93
 
94
[Stack Overflow]: http://stackoverflow.com/
95
[@typeahead]: https://twitter.com/typeahead
96
[so tag]: http://stackoverflow.com/questions/tagged/typeahead.js
97
 
98
Issues
99
------
100
 
101
Discovered a bug? Please create an issue here on GitHub!
102
 
103
https://github.com/twitter/typeahead.js/issues
104
 
105
Versioning
106
----------
107
 
108
For transparency and insight into our release cycle, releases will be numbered
109
with the follow format:
110
 
111
`<major>.<minor>.<patch>`
112
 
113
And constructed with the following guidelines:
114
 
115
* Breaking backwards compatibility bumps the major
116
* New additions without breaking backwards compatibility bumps the minor
117
* Bug fixes and misc changes bump the patch
118
 
119
For more information on semantic versioning, please visit http://semver.org/.
120
 
121
Testing
122
-------
123
 
124
Tests are written using [Jasmine] and ran with [Karma]. To run
125
the test suite with PhantomJS, run `$ npm test`.
126
 
127
<!-- section links -->
128
 
129
[Jasmine]: http://pivotal.github.com/jasmine/
130
[Karma]: http://karma-runner.github.io/
131
 
132
Developers
133
----------
134
 
135
If you plan on contributing to typeahead.js, be sure to read the
136
[contributing guidelines]. A good starting place for new contributors are issues
137
labeled with [entry-level]. Entry-level issues tend to require minor changes
138
and provide developers a chance to get more familiar with typeahead.js before
139
taking on more challenging work.
140
 
141
In order to build and test typeahead.js, you'll need to install its dev
142
dependencies (`$ npm install`) and have [grunt-cli]
143
installed (`$ npm install -g grunt-cli`). Below is an overview of the available
144
Grunt tasks that'll be useful in development.
145
 
146
* `grunt build` – Builds *typeahead.js* from source.
147
* `grunt lint` – Runs source and test files through JSHint.
148
* `grunt watch` – Rebuilds *typeahead.js* whenever a source file is modified.
149
* `grunt server` – Serves files from the root of typeahead.js on localhost:8888.
150
  Useful for using *test/playground.html* for debugging/testing.
151
* `grunt dev` – Runs `grunt watch` and `grunt server` in parallel.
152
 
153
<!-- section links -->
154
 
155
[contributing guidelines]: https://github.com/twitter/typeahead.js/blob/master/CONTRIBUTING.md
156
[entry-level]: https://github.com/twitter/typeahead.js/issues?&labels=entry-level&state=open
157
[grunt-cli]: https://github.com/gruntjs/grunt-cli
158
 
159
Maintainers
160
-----------
161
 
162
* **Jake Harding**
163
  * [@JakeHarding](https://twitter.com/JakeHarding)
164
  * [GitHub](https://github.com/jharding)
165
 
166
* **You?**
167
 
168
Authors
169
-------
170
 
171
* **Jake Harding**
172
  * [@JakeHarding](https://twitter.com/JakeHarding)
173
  * [GitHub](https://github.com/jharding)
174
 
175
* **Veljko Skarich**
176
  * [@vskarich](https://twitter.com/vskarich)
177
  * [GitHub](https://github.com/vskarich)
178
 
179
* **Tim Trueman**
180
  * [@timtrueman](https://twitter.com/timtrueman)
181
  * [GitHub](https://github.com/timtrueman)
182
 
183
License
184
-------
185
 
186
Copyright 2013 Twitter, Inc.
187
 
188
Licensed under the MIT License