1.0.4 • Published 5 years ago

qrcode-webpack-plugin v1.0.4

Weekly downloads
2
License
MIT
Repository
github
Last release
5 years ago

devserver-qrcode-webpack-plugin

npm.io npm.io

webpack-dev-server运行时在控制台打印二维码

webpack-server-qrcode

安装

$ npm install qrcode-webpack-plugin

使用

webpack.config.js

const QRcodeWebpackPlugin = require('qrcode-webpack-plugin')

module.exports = {
  devServer: {
    ...
    host: '0.0.0.0'
  },
  plugins: [
    new QRcodeWebpackPlugin()
  ]
}

确保电脑和手机处于同一个局域网内,手机扫码即可预览,手机端支持实时刷新。

License

MIT