mirror of
https://github.com/gigirassy/plaster.git
synced 2024-12-23 18:39:07 +00:00
Update client.js
This commit is contained in:
parent
0de22267d6
commit
5274eaaa4d
@ -10,8 +10,8 @@ document.getElementById('fetchBtn').addEventListener('click', async () => {
|
||||
throw new Error(errorData.error || 'Unknown error occurred');
|
||||
}
|
||||
|
||||
const data = await response.json();
|
||||
output.textContent = data.text;
|
||||
const text = await response.text(); // Always plain text
|
||||
output.textContent = text; // Display raw text
|
||||
} catch (error) {
|
||||
output.textContent = `Error: ${error.message}`;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user