如何在 Android 模擬器中“搖動”Android 設備以調出開發菜單來調試我的 React Native 應用程序

問題:

I am working on a cross-platform React Native mobile app.我正在開發一個跨平臺的 React Native 移動應用程序。 I am writing console.log statements as I develop.我在開發時正在編寫 console.log 語句。 I want to see these logging statements in Chrome while I'm running the Android app in the default Android emulator.當我在默認的 Android 模擬器中運行 Android 應用程序時,我想在 Chrome 中看到這些日誌語句。 According to Facebook's docs I just need to "shake the device".根據Facebook 的文檔,我只需要“搖動設備”。 How do I do this in the Android emulator?如何在 Android 模擬器中執行此操作?

To access the in-app developer menu:要訪問應用內開發者菜單:

On iOS shake the device or press control + ⌘ + z in the simulator.在 iOS 上搖動設備或在模擬器中按下 control + ⌘ + z。 On Android shake the device or press hardware menu button (available on older >devices and in most of the emulators, eg in genymotion you can press ⌘ + m to >simulate hardware menu button click)在 Android 上搖動設備或按下硬件菜單按鈕(適用於較舊的>設備和大多數模擬器,例如在 genymotion 中,您可以按 ⌘ + m 來>模擬硬件菜單按鈕單擊)


解決方案:

參考一: https://en.stackoom.com/question/2E6bh
參考二: https://stackoom.com/question/2E6bh
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章