You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Feature request: Autocomplete variants as function parameters #203
This looks very specific: assume there's a single unlabeled argument of type variant. Then try to autocomplete.
Feels like we need a more general proposal for this.
I just wanted to give a simple example for a common use case. Yes, it can be generalized in various ways, e.g. to multiple arguments, labelled arguments, uncurried invocation etc.
It also can be generalized to other situations where we know that a variant type is expected, e.g.
letaction: action=
It also can be generalized to functions with a record parameter, e.g.
Activity
cristianoc commentedon Apr 30, 2021
This looks very specific: assume there's a single unlabeled argument of type variant. Then try to autocomplete.
Feels like we need a more general proposal for this.
cknitt commentedon Apr 30, 2021
I just wanted to give a simple example for a common use case. Yes, it can be generalized in various ways, e.g. to multiple arguments, labelled arguments, uncurried invocation etc.
It also can be generalized to other situations where we know that a variant type is expected, e.g.
It also can be generalized to functions with a record parameter, e.g.
This sort of things generally works very well in TypeScript:
just getting started
zth commentedon Dec 29, 2022
Fixed in #665