josecebe / twbs-pagination

jQuery pagination plugin (bootstrap powered)
http://josecebe.github.io/twbs-pagination/
Other
1.1k stars 405 forks source link

ES6 module #178

Closed Glideh closed 6 years ago

Glideh commented 6 years ago

This wonderful little plugin seems not to be an importable module. Well, it seems to rely on jQuery being available globally as $. Am I wrong ?

If not I would be happy to do a PR about it (not having the time right now tough)

josecebe commented 6 years ago

So, the solution is to use 'jQuery' instead of '$'?

In my local machine seems to be working fine replacing all '$' by 'jQuery'.

Glideh commented 6 years ago

I personaly aliased jquery when I exposed it globally in my webpack config:

    plugins: [
        new webpack.ProvidePlugin({
            $: 'jquery'
        }),
    ],