I installed aws-sdk :- npm install aws-sdk
And then imported aws-sdk inside my worker file like this:
app.worker.ts :- import * as AWS from 'aws-sdk';
And then tried to console.log inside addEventListener code is here:-
addEventListener('message', async ({ data }) => {
console.log(AWS);
}
After doing this i am getting errors as in screenshot:
I also tried to solve this error for that i defined global in polyfills.ts though it's not working
polyfills.ts :- (window as any).global = window;
Any help will be greatly appreciated. What i am trying to achieve is i am trying to upload file from worker using aws-sdk to s3 from my angular project. Thank you guys!
