How to debug cordova/phonegap for windows phone - javascript

I'm new to windows phone development and found that I don't know how to debug a cordova/phonegap app with windows phone emulator.
I found out that using weinre (from here) it's possible to debug app, but still haven't found how to connect it with emulator (Using <script src="http://127.0.0.1:8080/client/"></script> in index.html have not worked, somehow it doesn't load all data like time response)
How can I debug my cordova/phonegap app for windows phone?

The easiest way to debug a Windows Cordova/Phonegap app is from Visual Studio. When you create your project and then add the Windows platform:
cordova create hello com.example.hello HelloWorld
cd hello
cordova platform add windows
Cordova will create a CordovaApp.sln file in the hello\platforms\windows directory. Open that up in Visual Studio 2013 (or open CordovaApp.vs2012.sln if you have Visual Studio 2012), select the project you want to debug in the Solution Explorer pane, select the emulator you want to run it in in the toolbar, and then hit F5 to start debugging. That's it!

Related

Cant open camera on cordova-android 11 with Quasar framework

I cannot open my camera in my phone using cordova-android 11 together with Quasar Framework.
Im using:
Gradle 7.42
SDK Build Tool: 32.0.0
Java 11.0.17
The app builds successfully and deploys to my physical android device but I am getting the error popup on my phone:
NorReadableError: Could not start video source
No errors in the terminal in VS code.
My guess it has something to do with permissions?
Anyone experienced the same? It seems to work on Android-cordova 9.0.0

I am unable to start up my React Native app on Windows using Android emulator from Android Studio

I am new to React Native and Mobile App Development. I am trying to start up my bare React Native project in my Emulator and it gives me issue to set up.
I get this error when I click on the button a to set to Android Emulator from my command terminal
Couldn't adb reverse: adb.exe: error: device offline
Couldn't start project on Android: Error running adb: device offline
please how do I fix it
here is my system variable
C:\Users\JUWONCALEB.DESKTOP-CMA289U\AppData\Local\Android\Sdk
running adb devices after running adb kill-server. Security question pops up after that. Worked for me.
1/ run npm start
2/ go to http://localhost:19002
3/ press on Lan and copy the URL under it eg. exp://192.168.1.3:19000
4/ download expo app in your device from your android studio.
5/ open expo and click Enter URL manually and paste the URL u copied in the previous step
6/ if needed: reload by clicking "r" button in your command line
Try to:
1 Launch the android emulator (any sdk is fine as any model)
2 open the settings IN the emulator
3 activate developer mode

Can i make console logs visible in a cordova app running on an emulator?

Hello i'am currently building an app with cordova and the quasar framework.
I'm experiencing some problems in my android version running on an emulator that dont happen in my web version.
Is there a way to make the errors visible in some way or another.
Im using android studio as my emulator.
Open a chrome window on the same machine the emulator is running on. Navigation to chrome://inspect/#devices, you should be able to debug the emulator from there, giving you the full devtools, providing the APK is a dev build. This will not work for production builds.

cp: /javascripts/phonegap.js: No such file or directory

PhoneGap is not installed in my mac. Now, I want to run a PhoneGap project with Xcode and I am getting this error. Can anyone tell me how to run the PhoneGap project in Xcode? I want to run the project from Junkyard-Jumbotron.
I can't comment yet, have you checked in the file directory to see if the file exists? Make sure you have met all of the requirements.
install the following:
- Xcode 4.3+
- Xcode Command Line Tools
- Intel-based computer with Mac OS X Lion or greater (10.7+)
- Necessary for installing on device:
-----Apple iOS device (iPhone, iPad, iPod Touch)
-----iOS developer certificate
Install the iOS SDK and Apache Cordova
- Install Xcode from the Mac App Store or Apple Developer Downloads
- Install the Xcode Command Line Tools (Xcode Preferences -> Downloads -> Components -> Command Line Tools -> Install).
- Download the latest release of [Apache PhoneGap
-----extract its contents
-----Apache Cordova iOS is found under lib/ios
Install CordovaLib
-Download the Cordova source
-Extract to source to their final permanent location on your hard drive (for example, to ~/Documents/CordovaLib-2.X.X)
- There is no step 3
Here is the link to getting started on a new project:
http://docs.phonegap.com/en/2.1.0/guide_getting-started_ios_index.md.html#Getting%20Started%20with%20iOS

How to debug cordova/phonegap app in windows phone emulator

I'm developing a windows phone app usign Cordova / Phonegap. I made it work for Android, but now that I'm trying wp for the first time I find myself with some unknown errors (some elements are not getting loaded).
How can I debug my javascript so I can get to know what is going wrong with my app?
It's very easy to debug a Windows Cordova/Phonegap app from Visual Studio. When you create your project and then add the Windows platform:
cordova create hello com.example.hello HelloWorld
cd hello
cordova platform add windows
Cordova will create a CordovaApp.sln file in the hello\platforms\windows directory. Open that up in Visual Studio 2013 (or open CordovaApp.vs2012.sln if you have Visual Studio 2012), select the project you want to debug in the Solution Explorer pane, select the emulator you want to run it in in the toolbar (or select Device to run it on an actual device), and then hit F5 to start debugging. You can set breakpoints in your Javascript code just like you would in C# or VB.

Categories