Open faulhaber opened 1 month ago
Try to find a new way to display images in PBUI, proposal:
function isImageUrl(url) {
return new Promise((resolve) => {
const img = new Image();
img.onload = () => resolve(true);
img.onerror = () => resolve(false);
img.src = url;
});
}
isImageUrl('https://example.com/image.jpg').then(isImage => { console.log(isImage); // true o false });
2. Otherwise, redirect to the URL.
To test the problem of linked images, see: BETA manid 1110 (Madrid: Biblioteca Nacional de España, MSS/12793 V. 1) The link to the digital facsimile in the BNE is found in the INTERNET field BETA manid 1110 (pb.cog)
Based on issue#189