getnotes not working SyntaxError: Unexpected end of input at NoteState.js:22:1
thakoraarya opened this issue · comments
aarya thakor commented
// Get all Notes
const getNotes = async () => {
// API Call
const response = await fetch(`${host}getnotes`, {
method: 'GET',
mode: 'no-cors',
headers: {
'Content-Type': 'text/html',
"auth-token": token
}
})
const jsn = await response.json()
console.log(jsn);
}
Failed to load resource: the server responded with a status of 401 (Unauthorized)