const baseUrl = process.env.NEXTPUBLICBASE_URL; export async const GET=async()=> { const…
- User
const baseUrl = process.env.NEXT_PUBLIC_BASE_URL; export async const GET=async()=> { const res = await fetch(
${baseUrl}/home, { method: "GET", headers: { "Content-Type": "application/json", }, }); const data = await res.json(); return Response.json(data) } TS1160: Unterminated template literal. - Assistant
The TypeScript error
TS1160: Unterminated template literalindicates that there is an issue with how template literals are being used in your code. However, in the code snippet you provided, the template literal seems correctly terminated. The issue may be in the surrounding code or might have been resolved elsewhere in your codebase.