You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by Piotr Zalewa <pz...@mozilla.com> on 2014/03/17 22:39:47 UTC

Installing mobile spec for testing API plugins only

Hi

I'm trying to install mobilespec to test under installed Cordova 
(3.4.0-0.1.0).

$ git clone git@github.com:zalun/cordova-mobile-spec.git
$ cordova create mobilespec
$ cd mobilespec
$ rm -rf www
$ ln -fs ../cordova-mobile-spec www
$ cordova platform add firefoxos
$ cordova plugin add ../cordova-mobile-spec/dependencies-plugin

And then adding a plugin from my directory (as usually with mobilespec)

On all pages I'm seeing
"Could not find cordova.js script tag. Plugin loading may fail." 
cordova.js:1213

When trying to test There is an error
ReferenceError: device is not defined
in this line:
console.log("Device="+device.platform+" "+device.version);

Am I doing something wrong?

Thanks
Piotr

Re: Installing mobile spec for testing API plugins only

Posted by Martin Gonzalez <ma...@gmail.com>.
Hi Piotr, I think that you need to add an updated js file for your platform  
as well, you can find it under cordova-js repository, there you can find the  
cordova-firefoxOS.js that you need to rename it to cordova.js and transfer  
to the project.

Or if you are using Mac Os, you can run the createmobilespec.sh as well.

Regards,
Martin.

-----Original message-----
From: Piotr Zalewa <pz...@mozilla.com>
To: "dev@cordova.apache.org" <de...@cordova.apache.org>
Sent: Mon, 17 Mar 2014, 21:40:19 GMT+00:00
Subject: Installing mobile spec for testing API plugins only

Hi

I'm trying to install mobilespec to test under installed Cordova 
(3.4.0-0.1.0).

$ git clone git@github.com:zalun/cordova-mobile-spec.git
$ cordova create mobilespec
$ cd mobilespec
$ rm -rf www
$ ln -fs ../cordova-mobile-spec www
$ cordova platform add firefoxos
$ cordova plugin add ../cordova-mobile-spec/dependencies-plugin

And then adding a plugin from my directory (as usually with mobilespec)

On all pages I'm seeing
"Could not find cordova.js script tag. Plugin loading may fail." 
cordova.js:1213

When trying to test There is an error
ReferenceError: device is not defined
in this line:
console.log("Device="+device.platform+" "+device.version);

Am I doing something wrong?

Thanks
Piotr