twitchdev / issues

Issue tracker for third party developers.
Apache License 2.0
73 stars 6 forks source link

Twitch extension JavaScript Helper .onContext not firing on config screen when set as component #520

Open cloutship opened 2 years ago

cloutship commented 2 years ago

Brief description

Environment: Hosted Test

We're seeing an issue with the Twitch extension JS helper. Specifically, the .onContext event. When an extension is activated as a Component and we click the gear icon to go to the config page, that event never fires. We've seen the expected behavior work when an extension is set as a Panel and the gear icon is clicked, that event fires and the context.mode is 'config'.

How to reproduce

Expected behavior

onContext event should trigger. This behavior does work when the extension is set as a Panel. The event will trigger as expected. It's only when the extension is set as a Component.

Screenshots Expected context object - as seen when the extension is set as a Panel: image

Additional context or questions

Our extensions routing is based off of what the context object returns to us. i.e. if context.mode = 'config', we route to and display the config page. The above scenario is breaking our first time user setup flow when they install the extension as a Component.

BarryCarlyon commented 2 years ago

Duplicate of #513