DOMException: SecurityErrorDOMException: SecurityError
A security-sensitive operation was blocked by the browser's security policies.
SyntaxError: await is only valid in async functionsThe await keyword was used outside of an async function.
You used await inside a regular (non-async) function. The await keyword can only be used inside functions marked with async, or at the top level of ES modules (top-level await).
Add the async keyword to the function containing await: async function getData() { ... }. For top-level await, ensure your file is treated as an ES module. Or use .then() instead of await.
function getData() { await fetch('/api'); } // SyntaxError: missing asyncDOMException: SecurityErrorA security-sensitive operation was blocked by the browser's security policies.
SyntaxError: JSON.parse unexpected characterJSON.parse() encountered invalid JSON syntax, such as single quotes, trailing commas, or unquoted keys.
DOMException: NetworkErrorA network operation failed, typically during a fetch request when the network is unreachable.
ENOTDIRA directory operation was attempted on a path that is not a directory.
TypeError: x is not iterableA value that is not iterable was used where an iterable was expected, such as in a for...of loop or spread operator.
TypeError: x is not a functionAn attempt was made to call a value as a function when it is not a function.