VSCode - Debug Javascript Templates

This feels like a really dumb question, I feel like I should be able to figure this out. But I’ve been trying to figure it for hours and I’m no further ahead than when I started. How does one see the results in a console or debug javascript templates like this one take from a custom button in VSCode?

    if (states['input_boolean.home_override_jason'].state == 'on')
      if (states['binary_sensor.jason_home'].state == 'on')
        return 'HOME';
      else
        return 'AWAY';
    else if (states['person.jason'].state == 'home')
      return 'HOME';
    else if (states['person.jason'].state == 'not_home')
      return 'AWAY';
    else
      return states['person.jason'].state.toUpperCase();