DEV Community

Discussion on: Cache Busting a React App

Collapse
 
abdullah727 profile image
abdullah727 • Edited

Hi,
i am facing an issue on production. Unable to access /meta.json endpoint..working fine on local.
getting this error: SyntaxError: Unexpected token < in JSON at position
Regards
Abdullah Saud

Collapse
 
takhine profile image
Aniketh Nair • Edited

I had the same issue, this change helped me

fetch('/meta.json',{
headers : {
'Content-Type': 'application/json',
'Accept': 'application/json'
}
})

Collapse
 
shauntrennery profile image
Shaun Trennery

@abdullah727 Did you ever manage to get the "Unexpected token