内容简介:在浏览器中打开
English | 中文
eruda-webpack-plugin
eruda 的 webpack 插件
使用
npm i --save-dev eruda-webpack-plugin
// webpack.config.js
const ErudaWebapckPlugin = reuire('eruda-webpack-plugin')
const HtmlWebpackPlutin = require('html-webpack-plugin')
const config = {
devServer: {
contentBase: path.join(__dirname, 'dist'),
port: 10000
},
mode: "development",
plugins: [
new HtmlWebpackPlutin({
template: path.resolve(__dirname, 'index.html')
}),
new ErudaWebapckPlugin()
]
}
在浏览器中打开 http://localhost:1000 就可以调试你的移动端网页了
使用 eruda 的插件
new ErudaWebapckPlugin({
plugins: ['fps', 'timing']
})
Options
force
eruda-webpack-plugin 默认只会在 development mode 生效, 如果你在其他 mode 中也想使用,可以设置 force 为 true
new ErudaWebpackPlugin({
force: true
})
tool
选择你想要使用的 eruda 的功能,默认会全部加载。
new ErudaWebpackPlugin({
tool: ['console', 'elements']
})
plugins
添加 eruda 的插件
new ErudaWebapckPlugin({
plugins: ['fps', 'timing']
})
以上就是本文的全部内容,希望本文的内容对大家的学习或者工作能带来一定的帮助,也希望大家多多支持 码农网
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
Introduction to Programming in Java
Robert Sedgewick、Kevin Wayne / Addison-Wesley / 2007-7-27 / USD 89.00
By emphasizing the application of computer programming not only in success stories in the software industry but also in familiar scenarios in physical and biological science, engineering, and appli......一起来看看 《Introduction to Programming in Java》 这本书的介绍吧!