I'm developing an app using Jhipster where I'm trying to show a <ng-select>
, that is not rendering as the attached file, I have also included the default theme (@import "~@ng-select/ng-select/themes/default.theme.css"
) in vendor.css and have rebuilt everything, it's not displayed too. Any help is appreciated.
Asked
Active
Viewed 312 times
0

Gaël Marziou
- 16,028
- 4
- 38
- 49

vhiguita857
- 31
- 5
-
Did you add the required [items] input ? – Nedim Kurbegović Nov 05 '18 at 10:19
-
Yes, I added it as an array from the TypeScript code, for example: public items:Array
= ['Amsterdam', 'Antwerp', 'Athens', 'Barcelona', 'Berlin']. – vhiguita857 Nov 14 '18 at 16:42 -
I tried to reproduce the issue with the newest version of Angular and it looks like I got the same problem as you. If you need a solution fast, can Ng Bootstrap Typeahead component satisfy your needs? – Nedim Kurbegović Nov 16 '18 at 09:24
-
Yes, I did that, with the Typeahead worked fine. Thanks. – vhiguita857 Nov 16 '18 at 16:31
1 Answers
1
I had the same issue as you and I solved it.
This is not an issue related to , but to any library you want to use.
To be able to add any thrid party library, you should follow the way jhipster is doing.
1- Create a module where to add the libraries module in import and export sections
2- Add this module (in import and export sections) to the shared.module.ts module.
A good example is here: https://medium.com/@cyril.casaucau/how-to-add-angular-material-on-an-jhipster-5-x-app-97c9569c9f97
Or simply add the NgSelectModule module to shared-libs.module.ts file.

Saber Chebka
- 87
- 4
-
From Review: Hi, while links are great way of sharing knowledge, they won't really answer the question if they get broken in the future. Add to your answer the essential content of the link which answers the question. In case the content is too complex or too big to fit here, describe the general idea of the proposed solution. Remember to always keep a link reference to the original solution's website. See: [How do I write a good answer?](https://stackoverflow.com/help/how-to-answer) – sɐunıɔןɐqɐp Jan 23 '19 at 11:19