Error when parsing hbs files
Closed this issue · 3 comments
I'm having this error when opening raw hbs
file. It looks like error only occurs when file content starts with the {
sign.
See an example here - link 1
See an example here - link 2. The second example does not throw an error, and I guess it's because the first character is not {
.
So, my assumption is that JSON view trying to beatify content if the file starts with the {
. In that case, we can try to skip the beatifying content of the file unless the URL ends with .json
or has no extension at all. Then in the case of .{js,hbs,any_other,...}
extension - no error will be thrown.
P.S. I can help with the fix, once we confirm which option is better. Thank you.
Neither of those files is JSON.
@bhollis Emm, I know and that's the problem. JSON view extension is trying to parse those files even though they are not JSON, please open link 1 and link 2
@bhollis please, reopen the issue