I’m running a website which includes multiple JS scripts in the section. It does a lot of work server side as that’s best for SEO.
Unfortunately my Sentry account is filled with errors such as
ReferenceError: getScriptTag is not defined
… which are caused when a script fails to load on mobile but JS further down the page still executes. Note getScriptTag is a global utility function.
Is there a way to stop reporting errors if script source files fail to load or is there a better pattern that I should be following here?