Package Managers

Download on GitHub

Currently: v3.2.2

Install

npm:

$ npm install jquery-drawer jquery@2.2.4 iscroll

Bower:

$ bower install drawer jquery#2.2.4 iscroll

Webpack

// webpack.config.js
var webpack = require('webpack')

module.exports =  {
  plugins: [
    new webpack.ProvidePlugin({
      $: 'jquery',
      jQuery: 'jquery',
      IScroll: 'iscroll',
    }),
  ],
}
// your-project.js
var IScroll = require('iscroll');
var $ = require('jquery');
require('jquery-drawer');

$('.drawer').drawer();

Browserify

// your-project.js
IScroll = require('iscroll');
var $ = jQuery = require('jquery');
require('jquery-drawer');

$('.drawer').drawer();

postcss-import

/* your-project.css */
@import "jquery-drawer";

Sass (scss).

/* your-project.scss */
@import "./node_modules/jquery-drawer/scss/drawer.scss";