How to integrate jQuery with TypeScript?

How to integrate jQuery with TypeScript?

I tried using jQuery in my TypeScript project with the following code:

$(function(){ 
    alert('Hello'); 
});

However, Visual Studio throws an error: (TS) Cannot find name ‘$’. How can I properly use jQuery with TypeScript and resolve this issue?