leewinder / ng2-file-drop

An Angular module for simple desktop file drag and drop with automatic file validation and dynamic style adjustment.
MIT License
28 stars 26 forks source link

Error when AOT compiling #31

Closed RenanCostaNascimento closed 6 years ago

RenanCostaNascimento commented 7 years ago

Hi there! Just passing by to let you know of a possible issue when compiling with AOT. My error message was the following:

ERROR in Error encountered resolving symbol values statically. Calling 
function 'ɵmakeDecorator', function calls are not supported. Consider 
replacing the function or lambda with a reference to an exported function, 
resolving symbol NgModule in /my-angular-app/node_modules/ng2-file-drop/node_modules/@angular/core/core.d.ts ...

I'm not sure whay that happened, but I changed the name of node_modules in your library to NOT_node_modules and the app compiled perfectly.

The problem I was facing is also described here: https://github.com/angular/angular-cli/issues/3707

I found out the solution by reading jeradg's comment in there. Take a look at what he says, maybe it can help you.

wnabil commented 7 years ago

update to version 1.1.0 its fixed already and there is an issue for this

RenanCostaNascimento commented 7 years ago

Hmm, weird... I already have 1.1.0 but the extra node_modules its still there.

wnabil commented 7 years ago

remove old node modules folder and clear the npm cache then try to install again

needsmorecoffee commented 7 years ago

Is it possible to get a new version without the node_modules folder included?

leewinder commented 6 years ago

This will be resolved in the latest version (fixed in both v5.0.0 and v4.0.0)

gaiottino commented 6 years ago

I'm still getting this issue? I'm using ng-cli but my updates to tsconfig.json didn't help.