一蹭沛、screenfull簡介
官網(wǎng)地址:https://github.com/sindresorhus/screenfull.js
二、組件安裝
npm install sreenfull --save
三势就、組件引入
在使用的頁面正確引入:
import screenfull from ‘screenfull’
模塊:
<a @click="fullscreen">
<i class="zmdi zmdi-fullscreen"></i>切換全屏
</a>
增加點擊全屏的方法:
fullscreen: function() {
// 全屏切換
screenfull.toggle();
}