我如何“摇一摇" Android模拟器中的一个Android设备,以调出开发菜单来调试我的React Native应用 [英] How do I "shake" an Android device within the Android emulator to bring up the dev menu to debug my React Native app

查看:414
本文介绍了我如何“摇一摇" Android模拟器中的一个Android设备,以调出开发菜单来调试我的React Native应用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发一个跨平台的React Native移动应用程序.我在开发时正在编写console.log语句.我想在默认的Android模拟器中运行Android应用时在Chrome中看到这些日志记录语句.根据 Facebook的文档,我只需要摇晃设备"即可.如何在Android模拟器中做到这一点?

I am working on a cross-platform React Native mobile app. I am writing console.log statements as I develop. I want to see these logging statements in Chrome while I'm running the Android app in the default Android emulator. According to Facebook's docs I just need to "shake the device". How do I do this in the Android emulator?

要访问应用内开发者菜单,请执行以下操作:

To access the in-app developer menu:

在iOS上,摇动设备或在模拟器中按Control +⌘+ z. 在Android上,摇动设备或按硬件菜单按钮(在较早的设备上和大多数仿真器中都可用,例如在genymotion中,您可以按⌘+ m来模拟硬件菜单按钮的点击)

On iOS shake the device or press control + ⌘ + z in the simulator. On Android shake the device or press hardware menu button (available on older >devices and in most of the emulators, e.g. in genymotion you can press ⌘ + m to >simulate hardware menu button click)

推荐答案

在Android仿真器中的应用内,在macOS上按 Command + M Ctrl + M (在Linux和Windows上).

Within your app in the Android Emulator press Command + M on macOS or Ctrl + M on Linux and Windows.

这篇关于我如何“摇一摇" Android模拟器中的一个Android设备,以调出开发菜单来调试我的React Native应用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆