VSCode: Is there an option to generate a function that doesn't exist yet, for Typescript?

Viewed 234

I would like to be able to call a function name that doesn't exist yet, and then be able to use quick actions to have it generate a function with that name. For example, using TypeScript if I type:

const name: string = 'Jon'
display(name)

I will get an error on display(name) that says Cannot find name: display because it doesn't exist yet.

What I want is a quick action to auto generate this function so it will write for me:

function display(name: string) {
  //TODO
}

Is there a plugin for this or anything? I'm relatively new to VSCode. I'm coming from android development, and Android Studio has this feature which saves me a lot of time.

0 Answers
Related