To resolve that, we need to reference more JS libraries as “polyfill” (sometimes called “shim”) to close the gap.
After extra JS files are referenced you can continue using PNP JS normally. As far as I can tell, there is no negative impact to other browsers by adding these JS polyfills. Cheers!
Download JS Polyfill
<!– IE 11 Polyfill – https://github.com/SharePoint/PnP-JS-Core/wiki/Install-and-Use#polyfill –>
- ReferenceError: ‘Promise’ is undefined (sp-pnp-js/dist/pnp.min.js:1:3661)
- Unhandled rejection ReferenceError: ‘Headers’ is undefined