[Typescript] Is there a way to quickly generate/derive parameters names from class names?

I call functions like this a lot:

function(workItem:WorkItem, project:Project, resources:Resources) {}

I.e. having a bunch of params that are named the same as some class name.

Is there a kind of auto suggest or "Generate..." for that to save all the typing?

0
2 comments

You can create a Live Template for this, like

$NAME$:$TYPE$

where $TYPE$ is set to jsClassName(), and $NAME$ - to decapitalize(TYPE):

1

OMG. This is so great! 

Thank you very much!

0

Please sign in to leave a comment.