How to import .ts file inside the .js file?

I am developing VS code extension. For that I need to know how to import .ts file inside the .js file. I tried deafferent ways to import but it doesn’t work for me. Can someone help me?

Here’s the JS file code and Error says “Uncaught ReferenceError: require is not defined”

(function () {

const axios = require('axios'); // Error: Uncaught ReferenceError: require is not defined

const vscode = acquireVsCodeApi();

console.log("hello there from javascript");

document.getElementById("circlein").onclick = function(){
    var x = document.getElementsByClassName("outline")[0];
    if (x.style.display === "none") {
      x.style.display = "block";
    } 
    setTimeout(()=>{
      x.style.display = "none"
    },4000);
}

})();

Can someone know how to solve this?