The background API returns the file stream generated by PDF. How to realize the preview at the front end?

problem description

API returns PDF file stream. Preview it at the front end

the environmental background of the problems and what methods you have tried

  • how can the file stream be obtained through js?
  • how to implement PDF preview?
  • how does PDF.js use file streams?
The

project is from 2016, which version of PDF.js is installed? node version is 4.4.4 and webpack is 1.14.1, crashing.

Sep.07,2021

you can just throw him your address


pdf can be previewed directly in the browser. Put the requested address directly into the address bar. Or embedded iframe. Or what plug-in to display


have you solved the problem? I also have this requirement qwq


want to know how to solve


window.open just preview it directly, as long as the stream is sent from the back end. The front end can be previewed directly.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b38875-2c12a.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b38875-2c12a.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?