Can you display a PhoneGap app as a Screencast in Chrome Developer Tools - google-chrome

Can't find an answer to this anywhere.
We have a prototype PhoneGap app that we deploy to Android devices. Using Chrome Developer tools we can debug it using the normal tools edit CSS etc and it will change the display on the device.
This is all great but I was wondering is there a way to use the screencast tool that displays your phone screen within developer tools for a phonegap app. From what I can tell it on;y seems to be able to pick up sites open in Chrome on the android device.
Any ideas would be greatly appreciated.
Thanks,
Ashley

Screencasting of WebViews is not supported at this time.
Maybe it's not exactly what you are looking for, but it helped me when troubleshooting:
Depending on the toolset you are using, you can try to access your local webserver on your development machine from the chrome browser on your android device. For this to work, the phone must be in your network (Wi-Fi).
I'm developing a PhoneGap app using Visual Studio and configured my environment to allow access from remote computers, see this blog post.
I also ran this command for my 'web site', found on the blog of Scott Hanselman:
C:\Program Files (x86)\IIS Express>IisExpressAdminCmd.exe
setupFriendlyHostnameUrl -url:http://yourcomputername:555/
Finally I was able to use the Screencasting feature, using the chrome browser from android.
Except that I was not able to use hardware features such as NFC, using the app via the browser felt the same.
For other environments, the procedure to enable remote access should be similar.
Martin

Related

Is there any way to install PWA from terminal command?

I'd like to install PWA from https://carbon.now.sh/ automatically.
It seems chrome has some commands like
https://www.ghacks.net/2013/10/06/list-useful-google-chrome-command-line-switches/
however, there is no installation of PWA...
Any idea is appreciated.
On Edge (Chromium based) for Windows and MacOS you can do this with a policy. Your question is about Chrome without a specific OS provided, so this doesn't directly answer your question, but this might be considered as an alternative if you don't need Chrome specifically. This could be useful in an Enterprise setting.
You can use Microsoft Edge Site as App functionality to do this, Open any website and then go to the menu (3 dots top-right) then go to apps and select install this site as an app and you are good to go.

Launch Desktop Application Chrome

So today, Google announced a desktop app launcher for its Google Drive service: http://googledrive.blogspot.ca/2014/11/launch-desktop-applications-from-google.html.
Any ideas on how they implemented this? I'd like to do the same for a personal project. I know there's a way in node-webkit to do something like this, but if this ever becomes a native capability within Chrome browser...
To quote the announcement:
To get started, install the latest version of the Drive app for Mac or PC (version 1.18) ...
They are using a native app (not a Chrome app) to provide the functionality. As such, they can do whatever they want.
You can replicate this with a Native Host + extension approach.

Is there a way to distribute your Chrome app with Chrome Browser?

I'm working on a Chrome app, and I'm wondering if there is a way to offer customers a single downloadable package that will provide both Chrome (the browser) and my app.
You sometimes see this with Java and Adobe AIR apps. You can either download just the app (if you already have the JVM or AIR, respectively), or you can download a package that includes the app plus the runtime.
In this case, Chrome is the runtime. Is there a way to offer a single download that will install Chrome along with my app? I can offer that as an option for users who do not already have Chrome installed.
This is something that is being actively developed now. The bug to follow is https://code.google.com/p/chromium/issues/detail?id=341353, but there isn't much visible there as it is being developed in an internal repository at Google.

Doubts on Phonegap.js, Phonegap Build and Intel XDK

I am very new to mobile application development. Now I am into a mobile application project which should work on IOS, Android, BB and WP.
After googling to learn what can I do on this, I felt Phonegap fulfils my requirement. I have downloaded and installed phonegap on eclipse to start develop for Android.
I have downloaded, SDK, AVD, eclipse etc to get started with Phonegap for Android.I followed the procedures in the Getting Started Guide.
For User Interface, I took Intel App Framework as my tool of choice.
Everything goes fine with me, other than my doubts in Cross Platform mobile application development.
1) I have read about PhoneGap build, it just requires html,css and js file to wrap up an application for different platforms. So downloading and linking phonegap.js in an the application is not required unless I need to access the device's native function ?
And just create a responsive HTML5 application and build with PhoneGap Build is all I have to do ?
2) If I can just do like above, then why I should install eclipse and android SDK to create for android when I can just make HTML5 application and build with phonegap build and put it on google play.
3) I have came across Intel XDK and they have similar service like phonegap, if I use Intel XDK then I don't have to use any assets of phonegap ?
Please answer these question as these things are confusing me a lot.
As per my knowledge these are the answers,
1) I have read about PhoneGap build, it just requires html,css and js
file to wrap up an application for different platforms. So downloading
and linking phonegap.js in an the application is not required unless I
need to access the device's native function ?
Yes, until your application need to access devices's native function or any inbuilt or custom plugins, no need of phonegap.js.
And just create a responsive HTML5 application and build with PhoneGap
Build is all I have to do ?
2) If I can just do like above, then why I should install eclipse and
android SDK to create for android when I can just make HTML5
application and build with phonegap build and put it on google play.
Phonegap applications need to be developed as native applications using web technologies,
ex: IOS apps need to developed on MAC (using IOS SDK) etc.
3) I have came across Intel XDK and they have similar service like
phonegap, if I use Intel XDK then I don't have to use any assets of
phonegap ?
Intel XDK using cloud based development where your html,css etc are uploaded into the Intel server and the application will build their and give your the final build. In this case you no need of MAC for IOS application development.
In my experience developing with Phonegap and its Build service I generally use a plain web IDE which is based on eclipse called Aptana. It's primary use is for just HTML web development. I never install iOS or Android SDK's since the whole reason you use Phonegap's online build service is so you can be free from having to set up multiple development environments.
All my project specifications are configured in the config.xml. I don't include a copy of Phonegap's libraries since they are bundled at the time of compilation in via Phonegap's online build service.
For general testing and debugging I use either the Chrome debug inspector or Chrome and the Ripple emulator. When I've finished testing and need to compile the binaries I send my code up to Phonegap's build service using maven and Chris Price's Phonegap build maven plugin.
This allows me to :
Unlock the signing keys (maven-ant-plugin and an http get call)
Upload my project for compilation to Phonegap's Build service
Sign my project with a specified signing key
Download a compiled binary for a specified platform
All from one single command. When I develop on my Mac Mini I installed a ruby script which will deploy the downloaded binary straight to my iOS device as final step.
I came up with this solution with the idea that I wanted to be able to checkout my code and be able to compile it online using only maven on any machine. This achieves that.
To answer #2. For phonegap you only need to download eclipse and android SDK or Xcode(iOS) if you are NOT using phone gap build. If you use Phonegap Build (included with Photoshop subscription) you can build with their servers and download the app straight to the device through the phonegap site. Its real simple for Android, a bit harder for iOS.
My understanding is that you have to subscribe to iOS Developer Program (US$99pa) to generate an iOS-installable app (even just for testing it), and publishing/distribution is also a bit more complicated than e.g. Android as well. That is completely regardless of what tool you use to build it, you need an Apple key code to install it. Of course, you can always just build and publish it as a a web application that be viewed in any browser. Then you don't need the iOS developer sub.

How standalone are packaged Chrome Apps?

I have a HTML5 app, that I need to redistribute as a desktop application. One solution could be Chrome packaged apps, but it seems you can only install those packages using the Chrome webstore.
Is there an easy way to distribute Chrome apps using a stand-alone installer, and without requiring the end-user to have Chrome installed?
You can install them using the .crx file given to you while packaging, but that still requires chrome. Actually, you pretty much have to somehow have chrome on the target, as the standalone apps use it's framework. Hope it helps.
The CefView example from the Chromium Embedded Framework project could server for this.