Q: Can't require directive in modlule This code generates an error on page open
Unknown provider: $cardProvider <- $card <- cardNumberDirective
Where is a mistake? I see that all should works, but it is not so.
angular.module('card', [])
.controller('CardCtrl', ['$scope', function ($scope) {}])

.directive('card', ['$compile', function ($compile) {
  return {
    restrict: 'A',
    scope: {
      cardContainer: '@',
      width: '@',
      placeholders: '=',
      options: '=',
      messages: '=',
    },
    controller: 'CardCtrl',
    link: function (scope, element, attributes, cardCtrl) {
      // Some logic is here...

      new Card(opts);
    }
  };
}])

.directive('cardNumber', ['$compile', function ($compile) {
  return {
    restrict: 'A',
    scope: {
      ngModel: '='
    },
    require: [
      '^card', // this directive can't be find
      'ngModel'
    ],
    link: function (scope, element, attributes, ctrls) {

    }
  };
}])

Thank you for any suggestions.

