Eslint parsing error because of global return in a component page

Getting an eslint parsing error because of global return that is used in the page loader-component. This mean that all of the code below return will not be check with eslint. Is there a work around?

  return {
    // Lifecycle Hooks....

Message - “parsing error return outside of function”

In my eslintrc.json file i have tried setting globalReturn

      "ecmaFeatures ": {
            "globalReturn": true

Did you try // eslint-disable-next-line before return?

Does not work, I also tried (see below), any other idea’s?

// eslint-disable-line
// eslint-disable-next-line

This is this rudimentary but I could comment out the return during checking :frowning:

let template = {
   // Lifecycle Hooks....

return template;