mirror of
https://github.com/devbridge/jQuery-Autocomplete.git
synced 2025-01-23 15:18:28 +00:00
Support Browserify. Closes #189
This commit is contained in:
parent
6f46c46356
commit
41f2c3fd95
@ -8,7 +8,7 @@
|
||||
*/
|
||||
|
||||
/*jslint browser: true, white: true, plusplus: true */
|
||||
/*global define, window, document, jQuery */
|
||||
/*global define, window, document, jQuery, exports */
|
||||
|
||||
// Expose plugin as an AMD module if AMD loader is present:
|
||||
(function (factory) {
|
||||
@ -16,6 +16,9 @@
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// AMD. Register as an anonymous module.
|
||||
define(['jquery'], factory);
|
||||
} else if (typeof exports === 'object' && typeof require === 'function') {
|
||||
// Browserify
|
||||
factory(require('jquery'));
|
||||
} else {
|
||||
// Browser globals
|
||||
factory(jQuery);
|
||||
|
Loading…
x
Reference in New Issue
Block a user