# DebugPopup 调试弹出层

调试面板,可以用来切换后端环境、清空缓存等。

H5、微信小程序正式版本下,默认不会显示,可通过设置 force-show 强制显示。

微信小程序正式环境通过 wx.getAccountInfoSync().miniProgram.envVersion (opens new window) 来判断。

# 引入

import PressDebugPopup from '@tencent/press-plus/press-debug-popup/press-debug-popup';

export default {
  components: {
    PressDebugPopup,
  }
}

# 代码演示

# 基础用法

<!-- #ifdef MP -->
<PressDebugPopup />
<!-- #endif -->

# API

# Props

参数 说明 类型 默认值
text 入口显示名称 string Y
force-show 是否强制展示 boolean false
other-buttons 按钮列表 array -
hook-test-net 是否改写 window.isTestNet 逻辑 boolean true
横屏