I am receiving a PDF as blob from API, I want to open it in new tab giving it a filename I want.
The file is being opened in new tab but the name and link looks like this
Link: "blob:http://localhost:3000/6ff6920c-2737-49cb-9359-e641e4af765d"
Name of PDF: "6ff6920c-2737-49cb-9359-e641e4af765d"
This name is different on each open
I am opening new tab with createObjectURL
const fileUrl = URL.createObjectURL(blob)
window.open(fileUrl);
So, I want to change the name of file when it is opened in new tab, instead of having auto-generated one.