VengeanceV
tRPC2y ago
2 replies
Vengeance

Send File Back From Procedure

Is there a way to send content like this back from a tRPC procedure?

  const headers = {
    "Content-Type": "application/vnd.apple.pkpass",
    "Content-Disposition": `attachment; filename=${passFilename}`,
    "Content-Length": passBuffer.length.toString(),
  };

  return new Response(passBuffer, { headers });
Was this page helpful?