What you’ve done is perfectly fine. The docs are trying to warn new users that they shouldn’t use LiveComponents unless their components are actually stateful, because if they have no reason to manage internal state it’s more efficient to use normal components. Your component, though, does manage its own state, so it’s just fine.
One tip, though: if you have a dropdown-style input like this, it’s much better to do the show/hide using the Phoenix.LiveView.JS module (e.g. JS.toggle or using classes) so that there is no latency for opening and closing the dropdown. Stuff like that can make your app feel a lot more responsive when you deploy it to a real server with real latency.






















