Skip to content
This repository has been archived by the owner on Feb 9, 2020. It is now read-only.

angular.module(...).decorator is not a function #275

Closed
op1ekun opened this issue Oct 27, 2015 · 6 comments
Closed

angular.module(...).decorator is not a function #275

op1ekun opened this issue Oct 27, 2015 · 6 comments
Assignees

Comments

@op1ekun
Copy link

op1ekun commented Oct 27, 2015

When batarang is on there's no .decorator() method in angular.module API.

Example:

angular.module( 'Demo', []);

angular.module('Demo')
    .factory('greeting', function greetingFactory() {
        // I return a greeting for the given name.
        return function (name) {
            return "Hello " + name + "." ;
        }
    });

angular.module('Demo')
    .decorator('greeting', function greetingDecorator($delegate) {

        return function() { 
            return $delegate(name) + ' How are you doing?';
        };
    });

Trying to call .decorator() gives me:

angular.module(...).decorator is not a function

ENV:
System: WIndows Server 2012 R2
Chrome: 46.0.2490.80 m
Plugin: 0.10.1
Angular: 1.4.7

@karptonite
Copy link

I can confirm that this is an issue. Angular 1.4.7.

@erwinmombay erwinmombay self-assigned this Nov 2, 2015
@erwinmombay
Copy link

will look into it

@Narretz
Copy link
Contributor

Narretz commented Dec 1, 2015

Can we possibly maybe fix .decorator and .component close to the 1.5 release (which may happen before Christmas)? I can help with the implementation.

@erwinmombay
Copy link

@Narretz for sure, i haven't had a chance to look at this yet (really sorry!). we have a hangouts this thursday at 2pm PST if you wanted to talk about it! if not feel free to leave any info here 👍

@petebacondarwin
Copy link
Member

Is there a PR for this yet? If not I think @Narretz will knock one up, right?

@petebacondarwin
Copy link
Member

Oh I just saw that it is here: #284

gkalpak pushed a commit to gkalpak/batarang that referenced this issue Feb 10, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants