Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unknown provider #4

Closed
contrastlogic opened this issue Jan 23, 2014 · 11 comments
Closed

Unknown provider #4

contrastlogic opened this issue Jan 23, 2014 · 11 comments

Comments

@contrastlogic
Copy link

Followed the instructions listed but running a view with FireUserLoginForm directive spits out this error in console:

Error: [$injector:unpr] Unknown provider: $firebaseAuthProvider <- $firebaseAuth <- $fireUser
http://errors.angularjs.org/1.2.6/$injector/unpr?p0=NaNirebaseAuthProvider%20%3C-%20%24firebaseAuth%20%3C-%20%24fireUser

@thataustin
Copy link
Collaborator

could you post any of your code? I think it would be helpful to see the markup and any controllers if you can.

@contrastlogic
Copy link
Author

Pretty basic setup

'use strict';

var app = angular.module('sandboxApp', ['ngCookies','ngResource','ngSanitize','ngRoute', 'fireUser'])
  .config(function ($routeProvider) {
    $routeProvider
      .when('/', {
        templateUrl: 'views/main.html',
        controller: 'MainCtrl'
      })
      .when('/foo', {
        templateUrl: 'views/foo.html',
        controller: 'FooCtrl'
      })
      .otherwise({
        redirectTo: '/'
      });

    //$locationProvider.html5Mode(true);
  });

/**
* FireUser
*
* FireUser - Firebase user management
*/
angular.module('fireUser').value('FireUserConfig', {
  FBurl: 'https://xxxxx.firebaseio.com'
});

app.controller('MainCtrl', ['$scope', function ($scope) {

    $scope.awesomeThings = [
      'HTML5 Boilerplate',
      'AngularJS',
      'Karma'
    ];

}]);

app.controller('FooCtrl', ['$scope', '$fireUser', function ($scope, $fireUser) {
    $scope.msg = 'testing';
}]);

-- foo.html

<p>This is the foo view.</p>
<fireuserloginform />

@thataustin
Copy link
Collaborator

are you using bower to install dependencies? I'd need to see if you have the correct deps included (angularFire, firebase, etc...) Also, if you want the buttons to show up, you'll need to include font awesome and twitter bootstrap as the instructions say.

@Jon-Biz
Copy link
Owner

Jon-Biz commented Jan 29, 2014

@contrastlogic - could you provide more information on the problem? Is it still occurring? Otherwise we are going to need to close this.

@contrastlogic
Copy link
Author

no resolution. not sure what more info you need. I'm using the default
yeoman angular setup, all libraries included and my code was posted.

Jason

On Wed, Jan 29, 2014 at 2:10 PM, Jon-Biz notifications@github.com wrote:

@contrastlogic https://github.com/contrastlogic - could you provide
more information on the problem? Is it still occurring? Otherwise we are
going to need to close this.

Reply to this email directly or view it on GitHubhttps://github.com//issues/4#issuecomment-33618607
.

@thataustin
Copy link
Collaborator

Ah, I think I found the problem. If you are using AngularFire version 0.6.0, then $firebaseAuth won't be defined. Can you check which version of that you are using? You should be able to look at the comments at the top of bower_components/angularfire/angularfire.js to find out.

We are currently working on upgrading to the latest version of angularfire (it's new), but in the meantime, an easy fix might be to bower uninstall angularfire, adjust the version in bower.json to be "~0.5.0", then bower install

@Jon-Biz
Copy link
Owner

Jon-Biz commented Feb 2, 2014

The current, master branch of FireUser has been updated to use AngularFire
0.6

However, there are significant other changes as well, that may or may not
effect your project as described here. I'm going to build your
project as described here tomorrow with the latest version of FireUser (0.2.1) and see if can
replicate/resolve your issue.

@contrastlogic
Copy link
Author

Version issue was correct. Just did a fresh Yeoman reinstall and bower dependancies. Still ran into an issue with AngularFire 0.6.0, but 0.5.0 appears to be working.

@thataustin
Copy link
Collaborator

@contrastlogic, we just updated to fireuser to v0.3.0, which uses angular fire 0.6.0. Feel free to try out the new version. Either way, would you mind closing this issue if you've worked this out?

@4ware
Copy link

4ware commented Aug 12, 2014

Hi! I'm trying to user FireUser with the latest angularfire v0.8.0 and run into the same error.

@richard457
Copy link

Did you inject firebase dependency on module if so then check the order of file because it matter too!
my case I hade ionicbundle after angularfire I guess you know firebase, my module was var starter = angular.module('starter', ['ionic',''])
corrected it like this: var starter = angular.module('starter', ['ionic','firebase'])
Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants