DonFabiolas
DonFabiolas

Reputation: 589

Angular Meteor 1.3 Ionic - how add ngCordova?

I would like to add ngCordova in my Angular Meteor 1.3 Ionic Project.

=> I've got this error on google chrome console : partyAdd.js:30 Uncaught TypeError: _angular2.default.module(...).component is not a function

=> I've got this error on Ios Simulator console (on Safari) : TypeError: _angular2['default'].module(name, [_angularMeteor2['default']]).component is not a function. (In '_angular2['default'].module(name, [_angularMeteor2['default']]).component', '_angular2['default'].module(name, [_angularMeteor2['default']]).component' is undefined)

Could you help me please to add ngCordova ? from this tutoriel : http://www.angular-meteor.com/tutorials/socially/angular1/ionic

Thank you

Upvotes: 0

Views: 220

Answers (2)

ABCD.ca
ABCD.ca

Reputation: 2495

npm install --save ng-cordova

Then, where you define your main app's angular module (in my case at the top of app.js) add:

import 'ng-cordova'

Of course, remove any Atmosphere package you might have had for ngCordova if you're upgrading from Meteor 1.2

Upvotes: 0

mariomol
mariomol

Reputation: 697

I found a solution, see it fits for you:

First install angular-component

  • meteor npm install --save angular-component

Then add in your main.js

  • import 'angular-component';

Upvotes: 0

Related Questions