The idea is to embed a pdf file on angular side that is being returned by node express server in blob form.
After then i get the image and created a URL
const file = new Blob([this.data], { type: 'application/pdf' });
this.fileUrl = URL.createObjectURL(file);
this.protectedUrl = this.sanitizer.bypassSecurityTrustUrl(this.fileUrl);
And then after i use this in html
<object ng-show="content" data="{{protectedUrl}}" type="application/pdf" style="width: 100%; height: 400px;"></object>