Recently, there is a project based on WeChat, using the vue framework. Due to the tight time and many component requirements, I tried to use the vux component framework to try.
官方demo:https://vux.li/demos/v2/?x-page=github#/demo;
After installing the project with vue_cli. Enter the project directory
<1>. Install vux in the project
npm install vux --save
<2>. Install vux-loader (there is no clear text in this vux document telling you to install it)
npm install vux-loader --save-dev
<3>. Install less-loader (this is used to compile the less source code correctly, otherwise ' Cannot GET / ' will appear, look at the package.json yourself, if it is installed, you don't need to install it!)
npm install less less-loader - -save-dev
<4>. Install yaml-loader (no need to install it)
npm install yaml-loader --save-dev
1) First introduce vux-loader
1
|
const vuxLoader = require(
'vux-loader'
)
|
2) Then replace the original module.exports with const webpackConfig , and then write such a piece of code at the bottom
1
2
3
|
module.exports = vuxLoader.merge(webpackConfig, {
plugins: [
'vux-ui'
]
|