autocomplete and function components