// zepto
module: {
rules: [
loaders: [{
test: resolve('static/js/zepto.js'),
loader: 'exports-loader?window.Zepto!script-loader'
}],
]
}
module.exports = vuxLoader.merge(baseConfig, {
plugins: ['vux-ui', 'duplicate-style', {
name: 'less-theme',
path: resolve('src/theme.less')
},
new webpack.ProvidePlugin({
$: 'https://static.360buyimg.com/finance/mobile/base/1.0.0/js/lib/zepto-1.1.4.js',
Zepto: 'https://static.360buyimg.com/finance/mobile/base/1.0.0/js/lib/zepto-1.1.4.js ',
'window.Zepto': 'https://static.360buyimg.com/finance/mobile/base/1.0.0/js/lib/zepto-1.1.4.js '
})]
})
// jquery
// main.js
import $ from 'jquery';
window.jQuery = $;
window.$ = $;
//
module.exports = vuxLoader.merge(baseConfig, {
plugins: ['vux-ui', 'duplicate-style',new webpack.ProvidePlugin({
$: "jquery",
jQuery: "jquery"
})]
})