Using the
import {Connection} from “tedious”;
and then
var conn = new Connection({});
it fails with error below
TypeError: globalThis.XMLHttpRequest is not a constructor
at checkTypeSupport (C:\Users\git\f-\edge\node_modules\rollup-plugin-node-polyfills\polyfills\http-lib\capability.js:20:11)
at node_modules/rollup-plugin-node-polyfills/polyfills/http-lib/capability.js (C:\Users\git\cfbdk\edge\node_modules\rollup-plugin-node-polyfills\polyfills\http-lib\capability.js:39:45)
at __init (C:\Users\deepa\AppData\Local\Temp\tmp-15672-onp53j9h2eo4\index.js:16:56)
at node_modules/rollup-plugin-node-polyfills/polyfills/http-lib/request.js
(C:\Users\git\cfbdk\edge\node_modules\rollup-plugin-node-polyfills\polyfills\http-lib\request.js:1:1)
at __init (C:\Users\deepa\AppData\Local\Temp\tmp-15672-onp53j9h2eo4\index.js:16:56)
at node-modules-polyfills:http (C:\Users\deepa\AppData\Local\Temp\tmp-15672-onp53j9h2eo4\node-modules-polyfills:http:30:1)
at __init (C:\Users\deepa\AppData\Local\Temp\tmp-15672-onp53j9h2eo4\index.js:16:56)
at node-modules-polyfills-commonjs:http (C:\Users\deepa\AppData\Local\Temp\tmp-15672-onp53j9h2eo4\node-modules-polyfills-commonjs:http:2:18)
at __require2 (C:\Users\deepa\AppData\Local\Temp\tmp-15672-onp53j9h2eo4\index.js:19:50)
at node_modules/@azure/msal-node/dist/msal-node.cjs.development.js (C:\Users\deepa\AppData\Local\Temp\tmp-15672-onp53j9h2eo4\index.js:56047:16)