[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?

Comment actions Permalink

You can create a Live Template for this, like


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

Comment actions Permalink

OMG. This is so great! 

Thank you very much!


Please sign in to leave a comment.