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

ctorParameters.map is not a function (wrong built solution?) #496

Closed
montella1507 opened this issue Dec 16, 2016 · 17 comments
Closed

ctorParameters.map is not a function (wrong built solution?) #496

montella1507 opened this issue Dec 16, 2016 · 17 comments

Comments

@montella1507
Copy link

montella1507 commented Dec 16, 2016

dragula problem

reflection_capabilities.js:58 Uncaught TypeError: ctorParameters.map is not a function
at ReflectionCapabilities.parameters (http://localhost:4200/main.bundle.js:56680:45)
at Reflector.parameters (http://localhost:4200/main.bundle.js:56814:44)
at CompileMetadataResolver.getDependenciesMetadata (http://localhost:4200/main.bundle.js:34977:54)
at CompileMetadataResolver.getTypeMetadata (http://localhost:4200/main.bundle.js:34942:26)
at CompileMetadataResolver.getDirectiveMetadata (http://localhost:4200/main.bundle.js:34717:28)
at http://localhost:4200/main.bundle.js:34786:49
at Array.forEach (native)
at CompileMetadataResolver.getNgModuleMetadata (http://localhost:4200/main.bundle.js:34779:44)
at http://localhost:4200/main.bundle.js:34767:50
at Array.forEach (native)

@montella1507
Copy link
Author

montella1507 commented Dec 16, 2016

It worked yesterday.. but today. i have reinstalled node_modules and it doesnt work.. mabye wrong built solution???

@montella1507 montella1507 changed the title ctorParameters.map is not a function ctorParameters.map is not a function (wrong built solution?) Dec 16, 2016
@paesku
Copy link

paesku commented Dec 16, 2016

To fix this quickly, use version 1.2.2-0
Basically this shouldn't happen with Semver.

Meanwhile I tried it with an @angular 2.2.3 setup which was working pretty well. I also tried @angular 2.2.0 which caused the same error.

@montella1507
Copy link
Author

I have to use version older than 2.2.0 because our solutions dont work after that "firebooster" version in IE11,.. Without any error.. Dragula worked for me with version 1.2.2-0 ysterday,.. but i have reinstalled Node_modules today and it throws that error :-/

@piyushxh
Copy link

Getting the error

"Uncaught TypeError: ctorParameters.map is not a function
at ReflectionCapabilities.parameters "

It works well with angular 2.2.3 but not with older versions of angular
My angular version is angular 2.1.1 with webpack.

Please help need solution in urgent.

Thank you

@nybroe
Copy link

nybroe commented Dec 23, 2016

I am seeing the same issue as @piyushxh
I see the issue in the console.
I am currently running @angular/core 2.1.0.

consoleerror

@piyushxh
Copy link

ok i found another npm package which is also good

ng2-dnd
check it out

@ghost
Copy link

ghost commented Dec 23, 2016

Hey guys any update on this? this morning I've updated my app

| - angular2-webpack-starter@5.0.5
| -- protractor@4.0.14
| -- webdriver-manager@10.3.0

And after those modules are updated the Uncaught TypeError: ctorParameters.map is not a function error appears.

I'm running angular 2.4.1, yesterday the app was worked fine.

@lufonius
Copy link

Hi

It seems to work with version 1.2.0. I get the error with version 1.2.2. I'm running angular 2.1.1.

Hope this helps someone. Cheers.

@LeahPike
Copy link

LeahPike commented Jan 6, 2017

I'm getting this error running ng2-dragula@1.2.0 as well as ng2-dragula@1.2.2.

@primaproxima
Copy link

I also have this error using 1.1.17 of ng2-bootstrap.
angular 2.1.2

@jashatton
Copy link

+1
I would like to see a fix for this too.

@leye0
Copy link

leye0 commented Jan 16, 2017

It also happens with value-software ng2-popover.

@valorkin
Copy link
Member

guys please compare your package.json to valor-software/ngx-bootstrap#1497 (comment)
and clean install deps
it is not an ng2-dragula issue

@Darguelles
Copy link

Here you got a few things i did to solve this problem, in my case i was tryin' to deploy my node app on a docker container but the dependencies were bad configured. I hope it helps.
http://stackoverflow.com/a/41733464/4433104

@azanebrain
Copy link

I've found that this issue is caused by any number of packages expecting the version of Angular Core to be different than what is actually installed.

I was able to figure out the cause of this issue by looking at the error report from ng build:

npm WARN @angular/platform-server@2.4.4 requires a peer of @angular/core@2.4.4 but none was installed.

This helped me realize that one of my packages expected Angular to be at v2.4.4, but I'm using v2.0.1. I updated my package.json to have both packages set to my core version like this:

"dependencies": {
    "@angular/core": "2.0.1",
    "@angular/platform-server": "2.0.1",
}

Your issue might not be with @angular/platform-server, but I hope this helps debug it

@oferh
Copy link

oferh commented Jul 17, 2017

looks like angular compiler cli issue

Try to import from src folder and not from main if it doesn't work may need to change the minimal Angular version that is supported.

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