Alberplz / angular2-color-picker

Angular 2 Color Picker Directive, no dependences required.
MIT License
185 stars 82 forks source link

Fix for compilation with AoT and AngularCLI #84

Closed Zerogiven closed 6 years ago

Zerogiven commented 7 years ago

Just a small fix for those errors: ERROR in Cannot determine the module for class TextDirective in .../node_modules/angular2-color-picker/lib/color-picker.directive.ts! Cannot determine the module for class SliderDirective in .../node_modules/angular2-color-picker/lib/color-picker.directive.ts! Cannot determine the module for class DialogComponent in .../node_modules/angular2-color-picker/lib/color-picker.directive.ts!

Zerogiven commented 7 years ago

Ups sorry, did not saw that it's already in progress with another pull request...

Zerogiven commented 7 years ago

But this patch would be needed for me and my team to make a succesfull build, so at the moment i copied your code into my src/ and import this with my fix till an update ;) cheers

chrishawn commented 7 years ago

thanks just ran into this as well... would be nice for it to drop into master soon

born2net commented 7 years ago

Hi, any chance we can get it working with ng-cli / AOT? Thanks for a great lib, just needing AOT support, Angular 2 Kitchen sink: http://ng2.javascriptninja.io and source@ https://github.com/born2net/Angular-kitchen-sink Regards,

Sean

Zerogiven commented 7 years ago

@born2net you can look at the "files changed" tab and make the changes by yourself at the moment. To have it in your repo i suggest you temporarily copy the angular color picker module inside your project (src/app, for example). After this you just have to import it from your directory location not from node_modules.

import { ColorPickerModule } from './your-folder-where-you-saved-the-color-picker.../';

cheers

born2net commented 7 years ago

tx I have used the other repo for now that added AOT. Tx for replying. https://github.com/zefoy/ngx-color-picker

ghost commented 7 years ago

Any news on this PR? When will be merged?