fix: fix compatibility with webpack 3

According to the documentation
https://vue-loader.vuejs.org/guide/extract-css.html#webpack-3
and some private feedbacks, there are still many users use
vue-loader v15 along with webpack 3.
parent 151995e5
const webpack = require('webpack')
let VueLoaderPlugin = null
if (webpack.version[0] > 4) {
if (webpack.version && webpack.version[0] > 4) {
// webpack5 and upper
VueLoaderPlugin = require('./plugin-webpack5')
} else {
......
......@@ -34,7 +34,7 @@
},
"peerDependencies": {
"css-loader": "*",
"webpack": "^4.1.0 || ^5.0.0-0"
"webpack": "^3.0.0 || ^4.1.0 || ^5.0.0-0"
},
"peerDependenciesMeta": {
"cache-loader": {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment