darrenjennings / vue-autosuggest

🔍 Vue autosuggest component.
https://darrenjennings.github.io/vue-autosuggest
MIT License
621 stars 91 forks source link

[Feature request] add componentAttrClassesAutosuggest #114

Closed FibreFoX closed 5 years ago

FibreFoX commented 5 years ago

Problem description:

Current implementation can take a custom ID, but lacks the ability to take a custom CSS class.

https://github.com/darrenjennings/vue-autosuggest/blob/242dd4dee084d5f6133c09b88da7f9e87f7502be/src/Autosuggest.vue#L2

Suggested solution:

Please add the ability to add a CSS-class too. This is needed to be able to add some position: relative style or other positioning styles.

darrenjennings commented 5 years ago

This is already a capability of the component just add a class to the component and it will pass through. id is special since we use it for Aria attributes.

<vue-autosuggest class="your-class" ...>
FibreFoX commented 5 years ago

Thanks a lot, it works like a charm ;) I'm new to VueJS, so thanks for that useful hint.