Hello,
I get errors when I comple with webpack
ERROR in ./node_modules/vx-easyui/dist/themes/icons/filesave.png 1:0
Module parse failed: Unexpected character '�' (1:0)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See
https://webpack.js.org/concepts#loadersmy congif
package.json
{
"name": "vue-jeasyui",
"version": "1.0.0",
"description": "vue-jeasyui",
"main": "webpack.config.js",
"scripts": {
"clean": "rimraf dist",
"build": "npm run clean && webpack --mode production",
"serve": "webpack-dev-server --mode development",
"test": "test"
},
"author": "MP",
"license": "MIT",
"devDependencies": {
"@babel/core": "^7.9.0",
"@babel/preset-env": "^7.9.0",
"babel-loader": "^8.1.0",
"css-loader": "^3.4.2",
"html-webpack-plugin": "^4.0.3",
"rimraf": "^3.0.2",
"style-loader": "^1.1.3",
"vue": "^2.6.11",
"vue-loader": "^15.9.1",
"vue-style-loader": "^4.1.2",
"vue-template-compiler": "^2.6.11",
"webpack": "^4.42.1",
"webpack-cli": "^3.3.11",
"webpack-dev-server": "^3.10.3"
},
"dependencies": {
"vx-easyui": "^1.2.6"
}
}
my webpack.config.js
const HtmlWebpackPlugin = require('html-webpack-plugin');
const VueLoaderPlugin = require('vue-loader/lib/plugin');
module.exports = {
entry: './src/main.js',
module: {
rules: [
{ test: /\.js$/, use: 'babel-loader' },
{ test: /\.vue$/, use: 'vue-loader' },
{ test: /\.css$/, use: ['vue-style-loader', 'css-loader']},
]
},
plugins: [
new HtmlWebpackPlugin({
template: './src/index.html',
}),
new VueLoaderPlugin(),
]
};
.babelrc.js
module.exports = {
presets: ['@babel/preset-env']
}
thanks