安装配置
main.js中
.vue页面中使用
data中定义变量
必要的样式
指定分页
在要进行分页的标签上,添加以下样式即可
例如,给section标签添加此样式,然后使用section标签实现分页
移除末尾的空白页
若打印时,末尾总是出现空白页,则存在定义了height:100%的元素,删除掉此样式即可
通常都是因为存在以下样式导致,通常被定义在全局样式文件中,或index.html中
若有的页面需要此样式,则在对应页面单独添加
安装配置
main.js中
.vue页面中使用
data中定义变量
必要的样式
指定分页
在要进行分页的标签上,添加以下样式即可
例如,给section标签添加此样式,然后使用section标签实现分页
移除末尾的空白页
若打印时,末尾总是出现空白页,则存在定义了height:100%的元素,删除掉此样式即可
通常都是因为存在以下样式导致,通常被定义在全局样式文件中,或index.html中
若有的页面需要此样式,则在对应页面单独添加
最近项目中使用打印功能,使用vue-print-nb最后打印没有样式,刚开始以为是不支持css预处理(s
同事遇到这样一个需求:在Chrome浏览器中希望可以静默打印,直接打印查了些资料,发现Chrome本身的设置就可以满足,同时Chrome的一些其他设置可以用在软件开发中.
举报文章
请选择举报类型
补充说明
0/200
上传截图
格式支持JPEG/PNG/JPG,图片不超过1.9M