Javascript – In NextJS, how can I show a blob of type 'image/jpeg', received from an API call, on screen?
In nextjs, I do the following API call: const response = await fetch('/api/generateimageHG2'); this call the following function: import { HfInference } from "@huggingface/inference"; export default async function generate (req, res) { try{ const inference = new HfInference('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'); const response…