Function parameters autocomplete for tables

First let’s start with checking how “function parameters autocomplete” for methods.
use this script:

--!strict
local function f(f: (Player, number) -> ()) end

try using this method, when it comes to parameters, the suggestion appears:


which is good, once accepted it inserts parameters (names could be better, but that’s OK, let’s leave them):

Now to the suggestion, let’s changes the script to:

--!strict

type args = {
	onEvent: (Player, number) -> ();
}

local function f(args: args) end

and try using it:


script analysis says:
image
and that’s correct.
let’s add onEvent:

also looks good so far.
let’s assign a function:

and that’s confusing: nothing helps with function parameters. Developers need to find and copy paste (or type manually) the parameters.

I would expect one more option:

  • function (anonymous autofilled)

This is the same quality of life function parameters have.
And it would help/improve developers performance as well.

Thank you!

2 Likes