oferh / ng2-completer

Angular 2 autocomplete component
http://oferh.github.io/ng2-completer/
MIT License
348 stars 171 forks source link

Material design not working #219

Open squareconcepts opened 7 years ago

squareconcepts commented 7 years ago

The normal version of of ng2-completer is working fine. But after copying the ng2-completer-md files to my angular2 project I get the following error:

If 'ng2-completer-md' is an Angular component and it has 'datasource' input, then verify that it is part of this module.

This is right, because there is no datasource input in the completer-cmp-md.ts file. There is an input dataService and this is deprecated. So I renamed dataService to datasource. After doing this I get the following error:

Uncaught (in promise): TypeError: Cannot read property 'selected' of undefined

How do I solve this?

oferh commented 7 years ago

ng2-completer-md is demo code so it's not equivalent to ng2-completer if you create a repo or plunk with code it'll be easier to understand what the issue is.

pueaau commented 6 years ago

Can't get it to work either. It would be nice if it was a proper part of the module.

ERROR in : Unexpected directive 'CompleterCmpMd in src/app/components/ng2-completer-md/completer-cmp-md.ts' imported by the module 'AppModule in src/app/app.module.ts'. Please add a @NgModule annotation.